title: AutoPostback for DropDownList in asp.net
body: <p>When I set AutoPostback=True for DropDownList, then only the SelectedIndexChanged event is fired otherwise not...</p>
  
  <p>I want to fire the event even when AutoPostback=false....</p>
  
  <p>Is there any solution for this...</p>
  
  <pre><code> &lt;asp:DropDownList ID="SlotDuration_DDL" runat="server" Style="color: #727272 !important; font-size: 24px; font-weight: 100;" CssClass="span2" OnSelectedIndexChanged="SlotDuration_DDL_SelectedIndexChanged"&gt;
  
        &lt;asp:ListItem&gt;10&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;15&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;20&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;25&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;30&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;35&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;40&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;45&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;50&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;55&lt;/asp:ListItem&gt;
        &lt;asp:ListItem&gt;60&lt;/asp:ListItem&gt;
    &lt;/asp:DropDownList&gt;
  </code></pre>
  
  <p>code behind</p>
  
  <pre><code>protected void SlotDuration_DDL_SelectedIndexChanged(object sender, EventArgs e)
  {
     DateTime dt = DateTime.Parse(StartDate_TB.Text);
          int n = Int32.Parse(EventDuration_DDL.SelectedItem.ToString());
          for (int i = 0; i &lt; n; i++)
          {
              Label NewLabel = new Label();
              NewLabel.ID = "Label" + i;
              var eventDate = dt.AddDays(i); //Calendar1.SelectedDate.Date.AddDays(i);
              NewLabel.Text = eventDate.ToLongDateString();
  
              CheckBox newcheck = new CheckBox();
              newcheck.ID = "CheckBox" + i;
  
              this.Labeldiv.Controls.Add(new LiteralControl("&lt;span class='h1size'&gt;"));
              this.Labeldiv.Controls.Add(NewLabel);
              this.Labeldiv.Controls.Add(new LiteralControl("&lt;/span&gt;"));
              this.Labeldiv.Controls.Add(new LiteralControl("&lt;div class='make-switch pull-right' data-on='info'&gt;"));
              this.Labeldiv.Controls.Add(newcheck);
              this.Labeldiv.Controls.Add(new LiteralControl("&lt;/div&gt;"));
              this.Labeldiv.Controls.Add(new LiteralControl("&lt;br/&gt;"));
  
          }
   }
  </code></pre>