Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
195
How to get the Selected row of child grid
posted

Hi,

I have one ighierarchical  grid  upto tow levels 0th and 1st

I have taken this grid using partial view and from the second level i have to set the option for user to select the row using the check box so to achive this i have added the template for that row

 gridModel.ColumnLayouts[0].Columns[0].Template = "<input id='${ItemID}'  type='checkbox'  ${IncludedText}  />";

where i have set the includedText like as checked or '' space to get that values

so my issue is am not able to get that selected row on the save button which is out side the grid .Please let me know is there any other option to select the child row by check box and getting that selected row id out side of grid . Please help me in this

  • 23953
    Offline posted

    Hello Kanha,

    I'm following to see whether you were able to resolve your issue.

    Let me know if you have further questions regarding this subject.

    Best regards,
    Martin Pavlov
    Infragistics, Inc.

  • 23953
    Offline posted

    Hello Kanha,

    You can do this with jQuery selector. You can change your template so that the input element contains a class with which you make sure that these are the inputs that you want to select.

    Example template:  "<input id='${ItemID}'  type='checkbox'  ${IncludedText} class='select-checkbox' />".

    With the above template your selector will look like this:

    $(".select-checkbox:checked")

    The next step is to iterate over all the selected checkboxes and using their id attribute to save them in your data source.

    Hope this helps,
    Martin Pavlov
    Infragistics, Inc.