I have a Reset button that should remove all filters - clearing the textbox as well as setting the menu to No Filter.
The problem is that I can only remove the text and the filter choice from one column. Here's a sample that works as expected:
function RemoveFilters() {
var masterTable = $find("<%= RadGrid1.ClientID %>").get_masterTableView();
masterTable.filter("Description", "", Telerik.Web.UI.GridFilterFunction.NoFilter);
}
However, when I try to add another column, the reset fails. This fails:
function RemoveFilters() {
var masterTable = $find("<%= RadGrid1.ClientID %>").get_masterTableView();
masterTable.filter(
"PartNumber", "", Telerik.Web.UI.GridFilterFunction.NoFilter);
masterTable.filter(
"Description", "", Telerik.Web.UI.GridFilterFunction.NoFilter);
}
Any idea how to fix this?
Ken
Microsoft MVP ASP.NET
| Protected Sub cmbNames_ItemsRequested(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmbNames.ItemsRequested |
| Dim conn As New SqlConnection("connstringhere") |
| Dim strSQL As String = "SELECT * FROM Members WHERE fName LIKE '%" & Me.cmbNames.Text & "%'" |
| Dim cmd As New sqlCommand(strSQL, conn) |
| conn.Open() |
| Dim table As New Data.DataTable |
| table.Load(cmd.ExecuteReader(data.CommandBehavior.CloseConnection) |
| Me.cmbNames.DataSource = table |
| Me.cmbNames.DataTextField = "fName" |
| Me.cmbNames.DataValueField = "ID" |
| Me.cmbNames.DataBind() |
| End Sub |
| <telerik:RadComboBox ID="cmbNames" runat="server" Skin="Telerik" Width="300px" |
| AllowCustomText="True" |
| AutoPostBack="True" |
| EnableLoadOnDemand="true" MarkFirstMatch="true"> |
| </telerik:RadComboBox> |
dock.ForbiddenZones[0] = "Zone Name";
But it keeps saying Index was outside the bounds of the array.
| XmlDataSource1.Data = myXElement.ToString(); |
| RadTreeView1.DataSource = XmlDataSource1; |
| RadTreeView1.DataBind(); |