I have a RadWindow that pops up with a couple of different FormViews on it. Each of these can be edited independently, etc.
I also have a RadComboBox on the top of my page, then should display the surrent "state" of the record. When it is changed I update the state as follows:
This works correctly. HOWEVER, every single time I click edit on any of my other formviews on the page, the combobox index gets changed and this gets called so it updates it automatically just by putting on of my formviews in edit mode.
Here is the combobox control on the page.
It is binded to the right control, but why when any of the other forms go into edit mode does it switch to 'New' and then run the index changed event? This shouldn't be executing at all unless the dropdown is physically changed right?
I also have a RadComboBox on the top of my page, then should display the surrent "state" of the record. When it is changed I update the state as follows:
Protected Sub list_appState_SelectedIndexChanged(ByVal o As Object, ByVal e As Telerik.Web.UI.RadComboBoxSelectedIndexChangedEventArgs) |
Dim record As Integer = (TryCast(Parent.FindControl("GridRec"), Label)).Text |
Dim AppState As String = (TryCast(formview_AppInfo.FindControl("list_appState"), RadComboBox)).SelectedValue |
Dim UpdateSuccess As Integer = Applications.UpdateAppState(record, AppState) |
If UpdateSuccess > 0 Then |
lbl_status.Text = String.Format("<br />The Application Status has been updated to '{0}' for record: {1}.<br /><br />", AppState, record) |
Dim grid As RadGrid = (TryCast(Parent.FindControl("grid_applications"), RadGrid)) |
End If |
End Sub |
This works correctly. HOWEVER, every single time I click edit on any of my other formviews on the page, the combobox index gets changed and this gets called so it updates it automatically just by putting on of my formviews in edit mode.
Here is the combobox control on the page.
<telerik:RadComboBox ID="list_appState" Runat="server" Skin="Sunset" SelectedValue='<%# Bind("app_state") %>' AutoPostBack="True" OnSelectedIndexChanged="list_appState_SelectedIndexChanged"> |
<Items> |
<telerik:RadComboBoxItem runat="server" Text="New/Working Lead" Value="New" ForeColor="Blue" /> |
<telerik:RadComboBoxItem runat="server" Font-Bold="True" |
Text="Dead Lead" Value="Dead" ForeColor="Red" /> |
<telerik:RadComboBoxItem runat="server" Font-Bold="True" |
Text="Sold To Customer" Value="Sold" ForeColor="Green" /> |
<telerik:RadComboBoxItem runat="server" Text="Customer Appointment" |
Value="Appointment" Enabled="False" ForeColor="#BA3D05" Font-Bold="True" /> |
<telerik:RadComboBoxItem runat="server" Text="Call Back" Value="Call Back" Enabled="False" ForeColor="#BA3D05" Font-Bold="True" /> |
<telerik:RadComboBoxItem runat="server" Text="Email Customer" Value="Email Customer" Enabled="False" ForeColor="#BA3D05" Font-Bold="True" /> |
<telerik:RadComboBoxItem runat="server" Text="Follow Up" Value="Follow Up" Enabled="False" ForeColor="#BA3D05" Font-Bold="True" /> |
<telerik:RadComboBoxItem runat="server" Font-Bold="True" |
Text="Credit Accepted" Value="Credit Accepted" Enabled="False" ForeColor="Green" /> |
<telerik:RadComboBoxItem runat="server" Font-Bold="True" |
Text="Credit Declined" Value="Credit Declined" Enabled="False" ForeColor="Red" /> |
<telerik:RadComboBoxItem runat="server" Font-Bold="True" |
Text="Credit Pending" Value="Credit Pending" Enabled="False" ForeColor="#BA3D05" /> |
</Items> |
<CollapseAnimation Duration="200" Type="OutQuint" /> |
</telerik:RadComboBox> |
It is binded to the right control, but why when any of the other forms go into edit mode does it switch to 'New' and then run the index changed event? This shouldn't be executing at all unless the dropdown is physically changed right?