I'm looking at http://www.telerik.com/help/aspnet-ajax/grid-griddataitem-get-nestedviews.html and http://www.telerik.com/help/aspnet-ajax/grid-traversing-detail-tables-items-in-grid.html.
I have a RadGrid with a header and detail records. What I need is to be able to find a control in the popup FormTemplate of a detail in JavaScript. Given what little I've been able to find so far I would expect it to be something like this:
var grid = $find('<%= RadGrid1.ClientID %>');
var masterTable = grid.get_masterTableView();
var dataItems = masterTable.get_dataItems();
var editForm = dataItems[0].get_nestedViews()[0];
var comboAssigned = $telerik.findControl(editForm, "ddlAssignedTo");
--------------------------------------
My apologies for once again posting too quickly. After some trial and (much) error I believe I've found an answer.
(Is this reasonably optimal? I know I'm going to have to use get_editFormItem if the template is in Edit mode.)
var grid = $find('<%=RadGrid1.ClientID %>');
var masterTable = grid.get_masterTableView();
var dataItems = masterTable.get_dataItems();
var nestedView = dataItems[0].get_nestedViews()[0];
var editForm = nestedView.get_insertItem();
var comboAssigned = $telerik.findControl(editForm, 'ddlAssignedTo');
I have a RadGrid with a header and detail records. What I need is to be able to find a control in the popup FormTemplate of a detail in JavaScript. Given what little I've been able to find so far I would expect it to be something like this:
var grid = $find('<%= RadGrid1.ClientID %>');
var masterTable = grid.get_masterTableView();
var dataItems = masterTable.get_dataItems();
var editForm = dataItems[0].get_nestedViews()[0];
var comboAssigned = $telerik.findControl(editForm, "ddlAssignedTo");
--------------------------------------
My apologies for once again posting too quickly. After some trial and (much) error I believe I've found an answer.
(Is this reasonably optimal? I know I'm going to have to use get_editFormItem if the template is in Edit mode.)
var grid = $find('<%=RadGrid1.ClientID %>');
var masterTable = grid.get_masterTableView();
var dataItems = masterTable.get_dataItems();
var nestedView = dataItems[0].get_nestedViews()[0];
var editForm = nestedView.get_insertItem();
var comboAssigned = $telerik.findControl(editForm, 'ddlAssignedTo');