I have grid that allow keyboard navigation in it .I wanna to refresh another grid while row navigation of the first one
I follow the solution in this thread
http://www.telerik.com/forums/radgrid-keyboard-navigation-trigger-select-row-on-keypress
but still the first row i selected exist within navigation by keyboard and can not get the id of the selected row by keyboard
JS :
Aspx:
Ajax:
C# :
Thanks....
I follow the solution in this thread
http://www.telerik.com/forums/radgrid-keyboard-navigation-trigger-select-row-on-keypress
but still the first row i selected exist within navigation by keyboard and can not get the id of the selected row by keyboard
JS :
function OnRowSelectedMP(sender, args) { alert("Row selected"); var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("SelectedMP"); }Aspx:
<telerik:RadGrid runat="server" ID="grd_ManPower_list" PageSize="5" CellSpacing="0" GridLines="None" OnSelectedIndexChanged="grd_ManPower_list_SelectedIndexChanged" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" ClientSettings-ClientEvents-OnRowDblClick="OnRowDblClick" OnNeedDataSource="grd_ManPower_list_NeedDataSource"> <MasterTableView DataKeyNames="id" ClientDataKeyNames="id"> <Columns> <telerik:GridBoundColumn DataField="id" FilterControlAltText="Filter column column" HeaderText="id" UniqueName="column" Visible="False"> <ColumnValidationSettings> <ModelErrorMessage Text="" /> </ColumnValidationSettings> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="Code" FilterControlAltText="Filter column1 column" HeaderText="Staff Code" UniqueName="column1"> <ColumnValidationSettings> <ModelErrorMessage Text="" /> </ColumnValidationSettings> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="Name" FilterControlAltText="Filter column2 column" HeaderText="Name" UniqueName="column2"> <ColumnValidationSettings> <ModelErrorMessage Text="" /> </ColumnValidationSettings> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="Trade" FilterControlAltText="Filter column3 column" HeaderText="Trade" UniqueName="column3"> <ColumnValidationSettings> <ModelErrorMessage Text="" /> </ColumnValidationSettings> </telerik:GridBoundColumn> </Columns> <PagerStyle Mode="NumericPages" /> </MasterTableView> <ClientSettings AllowKeyboardNavigation="true" EnablePostBackOnRowClick="true"> <ClientEvents OnRowSelected="OnRowSelectedMP" /> <Selecting AllowRowSelect="True" /> <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="true" FrozenColumnsCount="2" ScrollHeight="162px" /> </ClientSettings> </telerik:RadGrid>Ajax:
<AjaxSettings> <telerik:AjaxSetting AjaxControlID="grd_ManPower_list"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="RadGrid_prop_add" /> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings> <AjaxSettings> <telerik:AjaxSetting AjaxControlID="grd_ManPower_list"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="grd_ManPower_list" /> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings>C# :
else if (e.Argument == "SelectedMP") { foreach (GridDataItem item in grd_ManPower_list.SelectedItems) { if (item.Selected) {//// function load the other grid according to the selected item in first grid } } }Thanks....