title: Firing SelectedIndexChanged event , but the listbox's autopostback property is false - ASP.NET
body: <p>I am using an update panel . In this update panel, there is a listbox control. I actually set autopostback property to false in code behind. But still it executing SelectedIndexChanged event if the selected index is changed. </p>
  
  <p>Why this happens?</p>
  
  <pre><code>    &lt;asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional"&gt;
                                          &lt;ContentTemplate&gt;
  
                                              &lt;asp:MultiView ID="mvForms" runat="server" ActiveViewIndex="1"&gt;
                                                  &lt;asp:View ID="View1" runat="server"&gt;
                                                       &lt;asp:Panel ID="Panel5" runat="server" GroupingText="Available Evaluation Forms" meta:resourcekey="rsKey_panel5"
                                                       Width="100%"&gt;
                                                           &lt;asp:ListBox ID="lbAvailableForms" runat="server" AutoPostBack="true"
                                                               style="height: 125px; width: 95%;" 
                                                               onselectedindexchanged="lbAvailableForms_SelectedIndexChanged"&gt;&lt;/asp:ListBox&gt;
                                                        &lt;/asp:Panel&gt;
                                                  &lt;/asp:View&gt;
                                                  &lt;asp:View ID="View2" runat="server"&gt;
                                                       &lt;asp:Panel ID="Panel11" runat="server" GroupingText="Available Evaluation Forms" meta:resourcekey="rsKey_panel11"      Width="100%"&gt;
                                                          &lt;div  style="height: 125px; width: 95%; text-align:center;"&gt;
                                                              &lt;br /&gt;
                                                              &lt;br /&gt;
                                                              &lt;asp:Label ID="lblAllSelected" runat="server" Text="All Selected" meta:resourcekey="rsKey_lblAllSelected"&gt;&lt;/asp:Label&gt;&lt;/div&gt;
                                                      &lt;/asp:Panel&gt;
                                                  &lt;/asp:View&gt;
                                              &lt;/asp:MultiView&gt;
                                 &lt;/ContentTemplate&gt;
                               &lt;Triggers&gt;      
                             &lt;asp:AsyncPostBackTrigger ControlID="RLCompareParameter" EventName="SelectedIndexChanged"&gt;&lt;/asp:AsyncPostBackTrigger&gt;          
                              &lt;asp:AsyncPostBackTrigger ControlID="cbAllForms" EventName="CheckedChanged"&gt;&lt;/asp:AsyncPostBackTrigger&gt;
                          &lt;/Triggers&gt;
                        &lt;/asp:UpdatePanel&gt;            
  </code></pre>
  
  <p>The listbox name is lbAvailableForms.  While debugging i checked the autopostback property of this list box control, then i found that the property is false. Its looking so strange then how the selectedindexchanged event firing</p>
  
  <p>Here cbAllForm is a check box control and RLCompareParameteris a radilo list.</p>
  
  <p>Sometimes i need to get auto postback property is true. So initially i set this property to true.  under RLCompareParameter_SelectedIndexChanged event , i set lbAvailableForms.Autopostback=false. But still after setting the property to false ,the listbox firing selected indexchanged event</p>