title: ASP.net DropDownList, SelectedIndexChanged Not Working
body: <p>I tried every way but it didn't work at all. I would be glad if you can help. Trigger, AutoPostBack etc. I added everything, but still could not reach the solution in any way. Thank you.</p>
  <pre><code>&lt;%@ Page Language=&quot;C#&quot; AutoEventWireup=&quot;true&quot; CodeFile=&quot;prequest.aspx.cs&quot; Inherits=&quot;musteri_prequest&quot; validateRequest=&quot;false&quot; enableEventValidation=&quot;false&quot; viewStateEncryptionMode=&quot;Never&quot; %&gt;
  
  &lt;form id=&quot;form-login&quot; class=&quot;text-start&quot;&gt;
  &lt;form runat=&quot;server&quot;&gt;
      &lt;asp:ScriptManager runat=&quot;server&quot;&gt;&lt;/asp:ScriptManager&gt;
      &lt;asp:UpdatePanel ID=&quot;UpdatePanel1&quot; runat=&quot;server&quot;&gt;
          &lt;contenttemplate&gt;
              &lt;div class=&quot;mb-3&quot;&gt;
                  &lt;label class=&quot;form-label&quot; id=&quot;lbl-nombre&quot; for=&quot;txt-nombre&quot; style=&quot;font-family: Montserrat, sans-serif;font-size: 15px;font-weight: bold;&quot;&gt;Cihaz Seçiniz:&lt;/label&gt;
                  &lt;asp:DropDownList ID=&quot;prequ_cihaz&quot; runat=&quot;server&quot; AutoPostBack=&quot;True&quot; EnableViewState=&quot;true&quot; CssClass=&quot;form-control&quot; style=&quot;border-color: var(--first-color);margin-bottom: 15px;&quot; OnSelectedIndexChange = &quot;Prequ_cihaz_SelectedIndexChanged&quot;&gt;&lt;/asp:DropDownList&gt;
                  &lt;label class=&quot;form-label&quot; id=&quot;lbl-nombre-1&quot; for=&quot;txt-nombre&quot; style=&quot;font-family: Montserrat, sans-serif;font-size: 15px;font-weight: bold;&quot;&gt;Problem Türü:&lt;/label&gt;
                  &lt;asp:DropDownList ID=&quot;prequ_prob&quot; runat=&quot;server&quot; CssClass=&quot;form-control&quot; style=&quot;border-color: var(--first-color);margin-bottom: 15px;&quot;&gt;&lt;/asp:DropDownList&gt;
              &lt;/div&gt;
              &lt;div class=&quot;mb-3&quot;&gt;&lt;/div&gt;
              &lt;div class=&quot;mb-3&quot;&gt;&lt;/div&gt;
              &lt;div class=&quot;mb-3&quot;&gt;
                  &lt;asp:Label ID=&quot;prequest_label&quot; runat=&quot;server&quot; Text=&quot;&quot; style=&quot;color:rgb(148,0,211); font-family: Alatsi, sans-serif; margin-bottom: 9px;&quot; &gt;&lt;/asp:Label&gt;
                  &lt;label class=&quot;form-label&quot; id=&quot;lbl-nombre-1&quot; for=&quot;txt-nombre&quot; style=&quot;font-family: Montserrat, sans-serif;font-size: 15px;font-weight: bold;&quot;&gt;Probleminizi açıklayınız.&lt;/label&gt;
                  &lt;asp:TextBox ID=&quot;prequest_exp&quot; runat=&quot;server&quot; TextMode=&quot;MultiLine&quot; Rows=&quot;5&quot; CssClass=&quot;form-control form-control-lg&quot; style=&quot;border-color: var(--first-color);margin-bottom: 15px;&quot;&gt;&lt;/asp:TextBox&gt;
              &lt;/div&gt;
              &lt;div class=&quot;text-center&quot;&gt;
                  &lt;asp:Button ID=&quot;prequest_button&quot; runat=&quot;server&quot; onClick=&quot;prequest_button_Click&quot; Text=&quot;Gönder&quot; CssClass=&quot;btn btn-primary text-center&quot; style=&quot; background: var(--bs-indigo);&quot; /&gt;
              &lt;/div&gt;
           &lt;/contenttemplate&gt;
      &lt;/asp:UpdatePanel&gt;
  &lt;/form&gt;
  </code></pre>
  
  <code>
      protected void Prequ_cihaz_SelectedIndexChanged(object sender, EventArgs e)
      {
          a = prequ_cihaz.SelectedIndex;
          prequest_exp.Text = "Run!";
      }
  </code>