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

[Solved] Client side handling of itemCommand

1 Answer 112 Views
Grid
This is a migrated thread and some comments may be shown as answers.
robert
Top achievements
Rank 1
robert asked on 18 Apr 2008, 05:49 PM
Is is possible to trap and handle the click of a button in a GridButtonColumn on the client (cancelling the postback because I don't need the server to do anything)? 

Or, as an alternative, should I just use a template column and load it with a simple html image where the onclick is loaded with a call to my javascript functions in the page?  All I plan to do is open a RadWindow with additional information on the item clicked.  I thought the GridButtonColumn would be convenient to use, but I don't need to do anything in a server postback.


Regards,
Bob Reader

1 Answer, 1 is accepted

Sort by
0
Accepted
Sebastian
Telerik team
answered on 21 Apr 2008, 01:36 PM
Hello Robert,

You can use template column with hyperlink inside its item template as illustrated in these online resources:

http://www.telerik.com/DEMOS/ASPNET/Prometheus/Controls/Examples/Integration/GridAndWindow/DefaultCS.aspx?product=grid
http://www.telerik.com/support/kb/article/b454K-gmb-b454T-cba-b454c-cba.aspx

Thus you will be able to open your RadWindow instance with javascript upon clicking the link and pass row-related data to the pop-up. Feel free to modify the logic to meet your custom requirements.

Best regards,
Stephen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Grid
Asked by
robert
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Share this question
or