| <Columns> |
| <telerik:GridBoundColumn UniqueName="EmployeeNo" DataField="EmployeeNo" HeaderText="EmployeeNo" |
| HeaderStyle-Width="200px"> |
| <FilterTemplate> |
| <telerik:RadComboBox ID="RadComboBox1" DataTextField="EmployeeNo" DataValueField="EmployeeNo" |
| DataSource="<%# DataBindEmployeeNo() %>" |
| runat="server" > |
| <Items> |
| <telerik:RadComboBoxItem Text="All" /> |
| </Items> |
| </telerik:RadComboBox> |
| <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server"> |
| <script type="text/javascript"> |
| function EmployeeNoIndexChanged(sender,args) { |
| var tableView=$find("<%# ((GridItem)Container).OwnerTableView.ClientID %>"); |
| tableView.filter("EmployeeNo",args.get_item().get_value(),"EqualTo"); |
| } |
| function RemoveItem() |
| { |
| var combo = $find("<%= RadComboBox1.ClientID %>"); |
| var combocomboItem = combo.get_selectedItem(); |
| if(comboItem) |
| { |
| combo.trackChanges(); |
| combo.get_items().remove(comboItem); |
| combo.commitChanges(); |
| } |
| } |
| </script> |
| </telerik:RadScriptBlock> |
| </FilterTemplate> |
| </telerik:GridBoundColumn> |
</Column> |
<FilterTemplate>
<telerik:RadComboBox ID="RadComboBox1" >
</FilterTemplate>
I have a telerik:RadComboBox in FilterTemplate. I want to remove some items from it by client side.
I follow the demo http://www.telerik.com/help/aspnet-ajax/combo_itemsclientside.html but I can't get the combo in this way :
var combo = $find("<%= RadComboBox1.ClientID %>");
Compiler Error Message: CS0103: The name 'RadComboBox1' does not exist in the current context
Will it be some different in FilterTemplate?
Thank you!
var combo = $find("<%= RadComboBox1.ClientID %>");
Compiler Error Message: CS0103: The name 'RadComboBox1' does not exist in the current context
Will it be some different in FilterTemplate?
Thank you!