Skip to main content
Tab

ASPxComboBox.SelectedIndexChanged Event

Fires when the user changes the selection.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.1.dll

NuGet Package: DevExpress.Web

Declaration

public event EventHandler SelectedIndexChanged

Event Data

The SelectedIndexChanged event's data class is EventArgs.

Remarks

The editor handles the selection change on the server and raises the SelectedIndexChanged event in the following cases:

ASPxComboBox - SelectedIndexChanged

<dx:ASPxTextBox ID="ASPxTextBox1" runat="server" Text="Choose the country"></dx:ASPxTextBox>

<dx:ASPxComboBox ID="ASPxComboBox1" runat="server" OnSelectedIndexChanged="ASPxComboBox1_SelectedIndexChanged">
    <Items>
        <dx:ListEditItem Text="Afghanistan" Value="1" />
        <!--...-->
    </Items>
    <ClientSideEvents SelectedIndexChanged="function(s, e) { e.processOnServer=true; }" />
</dx:ASPxComboBox>
protected void ASPxComboBox1_SelectedIndexChanged(object sender, EventArgs e){     
    ASPxComboBox comboBox = (ASPxComboBox)sender;
    ASPxTextBox1.Text = comboBox.SelectedItem.ToString();
}
See Also