How to make row selection do postback?

5 posts, 0 answers
  1. Max McKinney
    Max McKinney avatar
    10 posts
    Member since:
    Aug 2009

    Posted 23 Nov 2009 Link to this post


    Through Telerik's examples I know how to
    -Cause Row Editing through a double or single  click on a row
    -how to enable the highlighting of a row from the client side settings
    -how to do client site row selection.  
    <ClientSettings EnableRowHoverStyle="true" >   
       <Selecting AllowRowSelect="True" />   

    I'll I am interesting in having is the EnableRowHoverStyle="true" and if they click on a row it does a postback to the 




    ItemCommand event for the grid?  Is this possible?  If so how is it done?  Last, where can I set the CommandName for this to happen?  I am not looking for a client event here.  I'm looking for a full postback.  I will handle the setting for the row being selected and all that in the code behind myself.








    Thank you

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 23 Nov 2009 Link to this post

    Hello Max,

    To get a full page postback on selecting rows in your grid, you can set the EnablePostBackOnRowClick property of the grid to true. Here's the link to the help article, where you can find more on this property:
    Making postback/ajax request on client row click

  3. Vance Smith
    Vance Smith avatar
    37 posts
    Member since:
    Jun 2012

    Posted 05 Jan 2010 Link to this post

    Hi, I have a similar problem. I am doing full grid editing and as a user tabs from column to column and then eventually a new row I would like the newly "selected" row to become selected so that the SelectedIndexChanged event will occur. How do I do that?

    Unfortunately, a user tabbing into one of the textboxes does not select the row...
  4. Radoslav
    Radoslav avatar
    1564 posts

    Posted 08 Jan 2010 Link to this post

    Hello Vance,

    If you want a row in edit mode to be selected you need to do the selection manually. You could try using client side selection:

    function ClientSideSelectedIndexChanged() {
        var masterTable = $find("<%=rgSchedule.ClientID%>").get_masterTableView();
        var dataItem = masterTable.get_dataItems()[0];

    You could call  this function on OnBlur event on the controls which are in edit mode (for example : on the last control on the row). Then you could get the row index  in which the control are placed and get the row via masterTable.get_dataItems[rowIndex];

    Another option to set item as selected is on the server, by setting its Selected property to true.

    Additionally, if you could elaborate on your scenario and on what exactly you are trying to achieve, you could try providing a proper resolution for your case.

    I hope this helps.

    Best wishes,
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  5. TonyG
    TonyG avatar
    239 posts
    Member since:
    Feb 2006

    Posted 22 Dec 2011 Link to this post

    RE: Princy's link from nov-23-2009, the help topic is now here.
Back to Top