I have a custom command item template similar to the top grid shown in http://demos.telerik.com/aspnet-ajax/grid/examples/programming/commanditem/defaultcs.aspx. What I am trying to do is, on the grid's
RowSelected() event update some of my controls (set enabled, or visibility) to accuratly show what the user is allowed to do with that particular row. For example - they may or may not be able to delete, or edit on a per-row basis. I am having trouble obtaining references to the controls in the template. If any javascript tries to reference a control inside the template, the entire grid dosn't render. I suspect this is due to the naming containers, the compiler can't find a reference to anything when declared such as (sample):
function RowSelected(sender, eventArgs) |
{ |
//Enable the update tab |
var tabStrip= $find("<%= RadTabStrip1.ClientID %>"); |
var tab = tabStrip.findTabByText("Update"); |
tab.set_enabled(true); |
} |
Because this template is not a typical row template, the other examples I have found regarding accessing controls inside templates do not seem to apply. How would one be able to get a reference to the client ids to use in javascript?
Thanks,
Kent