When I run the page without the Rebind() method call in my PreRender() method I get the desired filtering behavior, for the most part. We want the ComboBoxes to have a cascading data feature. When I set AppendDataBoundItems=”false” this does the trick but the user can no longer set the ComboBox to “ALL”. I put in a button to clear all the filters and that isn’t too bad. The problem I am running into now is when I have the ComboBoxes set and type in a first or last name that is invalid the page does nothing but says there is an error. I went to http://demos.telerik.com/aspnet-ajax/grid/examples/programming/filtertemplate/defaultvb.aspx and when you set the country to Argentina then set the filter for Is Promoted to yes the page loads http://demos.telerik.com/ErrorPageResources/error.aspx?aspxerrorpath=/aspnet-ajax/grid/examples/programming/filtertemplate/defaultvb.aspx this error. I thought that it was just a random connection but apparently your filters have the same issue that I am trying to overcome. I am guessing that you guys are aware of this issue, are there any suggestions on something that could be done? Or am I limited to trying to make the possibility of this happening as small as possible?
I also would like to have the ComboBoxes show all values that are on the same level as the current selection. For an example if it was States and Cities, and I had selected California for the state and Los Angeles for the City, I would like to click on the city combobox and have it display all cities in the state of California. Where would be a place to start looking for that possibility?
I thought maybe it would help to include a little more information from a prior question that this issue pertains to:
======================================================================================================
Posted on Nov 23, 2010 (permalink)
Posted on Nov 23, 2010 (permalink)
<MasterTableView AutoGenerateColumns="False" DataSourceID="SqlDataSource1" DataKeyNames="USER_ID" AllowMultiColumnSorting="true" Width="100%"><telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True" AllowPaging="True" AllowSorting="True" DataSourceID="SqlDataSource1" GridLines="None" Skin="Outlook" PageSize="100" EnableLinqExpressions="False" ShowGroupPanel="True" ShowStatusBar="True" AutoGenerateColumns="false"> <ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True" AllowDragToGroup="True"> <Selecting AllowRowSelect="True" /> <Scrolling AllowScroll="True" UseStaticHeaders="True" /> </ClientSettings> Protected Sub RadGrid1_PreRender(ByVal o As Object, ByVal e As EventArgs) Handles RadGrid1.PreRender If Not RadGrid1.MasterTableView.FilterExpression Is String.Empty Then FilterSetter() End If End Sub Private Sub FilterSetter() sqlLocationFilter.SelectCommand = "SELECT DISTINCT [DBOL] FROM [DBO]" & " WHERE " & RadGrid1.MasterTableView.FilterExpression.ToString() & " ORDER BY [Location]" sqlDepartmentFilter.SelectCommand = "SELECT DISTINCT [DOBD] FROM [DBO]" & " WHERE " & RadGrid1.MasterTableView.FilterExpression.ToString() & " ORDER BY [DBOD]" sqlOfficeFilter.SelectCommand = "SELECT DISTINCT [DBOO] FROM [DBO]" & " WHERE " & RadGrid1.MasterTableView.FilterExpression.ToString() & " ORDER BY [DBOO]" RadGrid1.MasterTableView.Rebind() End Sub Protected Sub ResetFiltersButton_OnClick(ByVal o As Object, ByVal e As EventArgs) RadGrid1.MasterTableView.FilterExpression = String.Empty For Each column As GridColumn In RadGrid1.MasterTableView.RenderColumns If TypeOf column Is GridBoundColumn Then Dim boundColumn As GridBoundColumn = TryCast(column, GridBoundColumn) boundColumn.CurrentFilterValue = String.Empty End If Next RadGrid1.Rebind() End Sub Protected Sub RadGrid1_ItemCommand(ByVal o As Object, ByVal e As GridCommandEventArgs) Handles RadGrid1.ItemCommand If e.CommandName = Telerik.Web.UI.RadGrid.ExpandCollapseCommandName Then Dim item As GridItem For Each item In e.Item.OwnerTableView.Items TestExpandEvent.Visible = True If item.Expanded And item IsNot e.Item Then item.Expanded = False End If Next End If End SubEnd ClassPosted on Nov 24, 2010 (permalink)
Protected Sub RadGrid1_PreRender(ByVal o As Object, ByVal e As EventArgs) Handles RadGrid1.PreRender If Not RadGrid1.MasterTableView.FilterExpression Is String.Empty Then FilterSetter() End IfEnd SubPrivate Sub FilterSetter() SqlLocationFilter.SelectCommand = "SELECT DISTINCT [Location] FROM [View_PhoneList_Debra] " & "WHERE " & RadGrid1.MasterTableView.FilterExpression.ToString() & " ORDER BY [Location]" SqlDepartmentFilter.SelectCommand = "SELECT DISTINCT [Department] FROM [View_PhoneList_Debra] " & "WHERE " & RadGrid1.MasterTableView.FilterExpression.ToString() & " ORDER BY [Department]" RadGrid1.MasterTableView.Rebind() End SubProtected Sub RadGrid1_ItemCommand(ByVal o As Object, ByVal e As GridCommandEventArgs) Handles RadGrid1.ItemCommand If e.CommandName = Telerik.Web.UI.RadGrid.ExpandCollapseCommandName Then Dim item As GridItem For Each item In e.Item.OwnerTableView.Items If item.Expanded And item IsNot e.Item Then item.Expanded = False End If Next End IfEnd SubPosted on Nov 26, 2010 (permalink)
FilterSetter(). At this point, your expanded item is gone, because the grid items are recreated.Posted 1 day ago (permalink)
When I run the page without the Rebind() method call in my PreRender() method I get the desired filtering behavior, for the most part. We want the ComboBoxes to have a cascading data feature. When I set AppendDataBoundItems=”false” this does the trick but the user can no longer set the ComboBox to “ALL”. I put in a button to clear all the filters and that isn’t too bad. The problem I am running into now is when I have the ComboBoxes set and type in a first or last name that is invalid the page does nothing but says there is an error. I went to http://demos.telerik.com/aspnet-ajax/grid/examples/programming/filtertemplate/defaultvb.aspx and when you set the country to Argentina then set the filter for Is Promoted to yes the page loads http://demos.telerik.com/ErrorPageResources/error.aspx?aspxerrorpath=/aspnet-ajax/grid/examples/programming/filtertemplate/defaultvb.aspx this error. I thought that it was just a random connection but apparently your filters have the same issue that I am trying to overcome. I am guessing that you guys are aware of this issue, are there any suggestions on something that could be done? Or am I limited to trying to make the possibility of this happening as small as possible?
I also would like to have the ComboBoxes show all values that are on the same level as the current selection. For an example if it was States and Cities, and I had selected California for the state and Los Angeles for the City, I would like to click on the city combobox and have it display all cities in the state of California. Where would be a place to start looking for that possibility?

Hi,
How to refresh the wizard from an event inside a usercontrol that forms part of the steps.
So for example, If I have a usercontrol inside step one and when a 'save button' in clicked in this user control, how to pass that to the wizard and change step visibility, icons etc.
Cheers,
Jack
<html xmlns="http://www.w3.org/1999/xhtml"><head id="Head1" runat="server"> <title></title> <link href="CustomSkin/PanelBar.Salt.css" rel="stylesheet" /> <style type="text/css"> .RadPanelBar_Salt a.rpLink.GreenPanel.rpExpandable.rpExpanded { background-color: green; background-position: 0 -1000px; border-color: green; } </style> </head><body> <form id="form1" runat="server"> <telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager> <telerik:RadSkinManager ID="RadSkinManager1" runat="server"></telerik:RadSkinManager> <%--<telerik:RadButton runat="server" Text="Preview Report" ></telerik:RadButton>--%> <telerik:RadPanelBar ID="RadPanelBar1" runat="server" ExpandMode="MultipleExpandedItems" Skin="Salt" EnableEmbeddedSkins="false" > <CollapseAnimation Duration="100" Type="None" /> <Items> <telerik:RadPanelItem runat="server" Text="Root RadPanelItem1" CssClass="GreenPanel" > <HeaderTemplate> Root Item 1 <asp:ImageButton ID="image1" runat="server" ImageUrl="~/images/save_go16x16.png" /><asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="~/images/ie_16x16.png" /> <a class="rpExpandable"> <span class="rpExpandHandle"></span> </a> </HeaderTemplate> <ContentTemplate> <telerik:RadTextBox ID="textbox1" runat="server" Text="text 1"></telerik:RadTextBox> <telerik:RadComboBox runat="server" ID="RadComboBox1" Text="combo1"></telerik:RadComboBox> </ContentTemplate> </telerik:RadPanelItem> <telerik:RadPanelItem runat="server" Text="Root RadPanelItem2" CssClass="GreenPanel" > <HeaderTemplate> Root Item 2<asp:ImageButton ID="ImageButton2" runat="server" ImageUrl="~/images/save_go16x16.png" /> <a class="rpExpandable"> <span class="rpExpandHandle"></span> </a> </HeaderTemplate> <ContentTemplate> <telerik:RadTextBox ID="RadTextBox1" runat="server" Text="Root Panel 2"></telerik:RadTextBox> <telerik:RadComboBox runat="server" ID="RadComboBox2" Text="combo2"></telerik:RadComboBox> </ContentTemplate> </telerik:RadPanelItem> <telerik:RadPanelItem runat="server" Text="Root RadPanelItem3" CssClass="GreenPanel" > <HeaderTemplate> Root Item 3<asp:ImageButton ID="ImageButton3" runat="server" ImageUrl="~/images/save_go16x16.png" /> <a class="rpExpandable"> <span class="rpExpandHandle"></span> </a> </HeaderTemplate> <ContentTemplate> <telerik:RadTextBox ID="RadTextBox3" runat="server" Text="Root Panel 3"></telerik:RadTextBox> <telerik:RadComboBox runat="server" ID="RadComboBox3" Text="combo3"></telerik:RadComboBox> </ContentTemplate> </telerik:RadPanelItem> </Items> <ExpandAnimation Duration="100" Type="None" /> </telerik:RadPanelBar> </form></body></html>
<telerik:RadGrid ID="RadGrid1" runat="server" CellSpacing="0" DataSourceID="sqlManufacturerSurvey" GridLines="None" AutoGenerateColumns="False"> <MasterTableView DataSourceID="sqlManufacturerSurvey" DataKeyNames="QuestionID" Name="Questions" HierarchyLoadMode="Client"> <CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings> <RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column"> <HeaderStyle Width="20px"></HeaderStyle> </RowIndicatorColumn> <ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column"> <HeaderStyle Width="20px"></HeaderStyle> </ExpandCollapseColumn> <Columns> <telerik:GridBoundColumn DataField="QuestionID" FilterControlAltText="Filter QuestionID column" HeaderText="QuestionID" UniqueName="QuestionID"> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="Question" FilterControlAltText="Filter Question column" HeaderText="Question" UniqueName="Question"> </telerik:GridBoundColumn> <telerik:GridTemplateColumn FilterControlAltText="Filter column column" UniqueName="Answer" HeaderText="Answer"> <ItemTemplate> <asp:RadioButtonList ID="rblAnswer" runat="server" DataSourceID="sqlResponses" DataTextField="Answer" DataValueField="AnswerID" RepeatLayout="Table"> </asp:RadioButtonList> </ItemTemplate> </telerik:GridTemplateColumn> </Columns> <EditFormSettings> <EditColumn FilterControlAltText="Filter EditCommandColumn column"> </EditColumn> </EditFormSettings> </MasterTableView> <FilterMenu EnableImageSprites="False"> <WebServiceSettings> <ODataSettings InitialContainerName=""> </ODataSettings> </WebServiceSettings> </FilterMenu> <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default"> <WebServiceSettings> <ODataSettings InitialContainerName=""> </ODataSettings> </WebServiceSettings> </HeaderContextMenu> </telerik:RadGrid> <asp:SqlDataSource ID="sqlManufacturerSurvey" runat="server" ConnectionString="<%$ ConnectionStrings:KPortal %>" SelectCommand="SELECT MaterialCategory.ServiceTypeID, Question.MaterialID AS QuestionID, Question.MaterialName AS Question FROM MaterialCategory INNER JOIN Materials AS Question ON MaterialCategory.MaterialCategoryID = Question.MaterialCategoryID WHERE (MaterialCategory.MaterialCategory = 'Manufacturer Survey') AND (Question.InternalCode = 'QUESTION')"> </asp:SqlDataSource> <asp:SqlDataSource ID="sqlResponses" runat="server" ConnectionString="<%$ ConnectionStrings:KPortal %>" SelectCommand="SELECT MaterialID AnswerID, MaterialName as Answer, ParentMaterialID as QuestionID FROM Materials WHERE (ParentMaterialID = @QuestionID)"> <SelectParameters> <asp:ControlParameter ControlID="RadGrid1" Name="QuestionID" PropertyName="SelectedValue" /> </SelectParameters> </asp:SqlDataSource> 