ASP.NET Dropdown box event fire

Normally Dropdown box is not fire event. to fire any event of dropdown box you need to write the AutoPostBack="True" property in dropdown control.

ASPX File:

  <asp:DropDownList ID="regionWingDropDownList" runat="server" Height="30px" Width="217px"  
           DataValueField="WingId" DataTextField="WingName" AutoPostBack="True"  
           style="margin-top: 0px"   

 protected void regionWingDropDownList_SelectedIndexChanged(object sender, EventArgs e)  
       Wing wing = new Wing();  
       wing.WingId = Convert.ToInt32(regionWingDropDownList.SelectedItem.Value);  
       regionDivisionDropDownList.DataSource = _regionManagerObj.GetSelectedWingAllDiviSionName(wing);  

Popular posts from this blog

mvc razor textboxfor change event change another textboxfor value

WPF Crystal Report Viewer Using SAP

ASP.NET MVC razor SAP Crystal report