asp.net - How to use ComboBox SelectedIndexChanged event

ComboBox SelectedIndexChanged event
ComboBoxOnSelectedIndexChanged.aspx

<%@ Page Language="C#" AutoEventWireup="true" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<!DOCTYPE html>
<script runat="server">
    void Combobox1_SelectedIndexChanged(object sender, EventArgs e)
    {
        Label1.Text = "You select: " + ComboBox1.SelectedItem.Text;
    }
</script>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Ajax ComboBox - How to use OnSelectedIndexChanged event in ComboBox</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2 style="color:DarkBlue; font-style:italic;">
            ASP.NET Ajax ComboBox - How to use
            <br /> OnSelectedIndexChanged event in ComboBox
        </h2>
        <hr width="425" align="left" color="LightBlue" />
        <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
        </asp:ToolkitScriptManager>
        <asp:Label 
            ID="Label1" 
            runat="server"
            Font-Size="Large"
            ForeColor="Crimson"
            >
        </asp:Label>
        <br /><br />
        <asp:ComboBox ID="ComboBox1" runat="server" 
            DropDownStyle="DropDown" 
            AutoCompleteMode="None"
            CaseSensitive="false"
            RenderMode="Block"
            AppendDataBoundItems="true"
            AutoPostBack="True"
            OnSelectedIndexChanged="Combobox1_SelectedIndexChanged"
            >
              <asp:ListItem Text="Red"></asp:ListItem>
              <asp:ListItem Text="Green"></asp:ListItem>
              <asp:ListItem Text="Blue"></asp:ListItem>
              <asp:ListItem Text="Orange"></asp:ListItem>
              <asp:ListItem Text="Crimson"></asp:ListItem>
        </asp:ComboBox>
    </div>
    </form>
</body>
</html>
More asp.net ajax example