This is a migrated thread and some comments may be shown as answers.

OnButtonClick event causes website to not work

2 Answers 59 Views
ToolBar
This is a migrated thread and some comments may be shown as answers.
Billy Rawls
Top achievements
Rank 1
Billy Rawls asked on 27 Jan 2012, 10:05 PM
I have a RadToolBar that I want to have use the OnButtonClick event. As soon as I set it, the whole associated RadGrid won't load. Any ideas?

<CommandItemTemplate>
            <telerik:RadToolBar ID="RadToolBar1" runat="server" OnButtonClick="RadToolBar1_OnButtonClick" >
                <Items>
                    <telerik:RadToolBarButton Text="Download"
                            CommandName="Download" Visible="true">
                    </telerik:RadToolBarButton>
                    <telerik:RadToolBarButton Text="View" CommandName="View"
                             Visible="true">
                    </telerik:RadToolBarButton>
                </Items>
            </telerik:RadToolBar>
</CommandItemTemplate>

2 Answers, 1 is accepted

Sort by
0
Accepted
Kate
Telerik team
answered on 31 Jan 2012, 02:33 PM
Hello Billy,

From the code provided it is not clear why you encounter this behavior of the RadGrid control. However, I would suggest that you take a look at this on-line demo that exemplifies how to use RadToolBar as a custom RadGrid Command item container.

Regards,
Kate
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
0
Billy Rawls
Top achievements
Rank 1
answered on 01 Feb 2012, 08:23 PM
I apologize for not responding earlier. The problem was entirely on my end. I had the event handler for the OnButtonClick event set to private, not protected. Thanks.
Tags
ToolBar
Asked by
Billy Rawls
Top achievements
Rank 1
Answers by
Kate
Telerik team
Billy Rawls
Top achievements
Rank 1
Share this question
or