title: How selecting javascript code to dropdown option from webbrowser
body: <p>I write a code for doing hot phone verify. But when I hit click then all field are filled but there is showing a “message”. How do I work on this code? </p>
  
  <pre><code>       &lt;div id="iPhoneSection" style="display: none"&gt;
                  &lt;div class="InputRow"&gt;
                      &lt;label id="iSmsHeading" for="DisplayPhoneCountryISO" class="Label" style="display: none"&gt;&lt;/label&gt;
                      &lt;div class="bottompad"&gt;
                          &lt;select id="DisplayPhoneCountryISO" name="DisplayPhoneCountryISO" aria-labelledby="iSmsHeading"&gt;&lt;/select&gt;
                      &lt;/div&gt;
                      &lt;div id="PhoneError" class="ErrMsg prooferror" style="display: none" aria-live="assertive" aria-relevant="text" aria-atomic="true"&gt;&lt;/div&gt;
                      &lt;div id="PhoneContainer" class="phcontainer"&gt;&lt;/div&gt;
                  &lt;/div&gt;
                  &lt;div class="toppad"&gt;
                      Verify phone via:
                      &lt;input id="idSMSChannel" type="radio" name="nameMNCChannel" value="SMS" class="inlineRadio" checked /&gt;
                      &lt;label for="idSMSChannel"&gt;Text&lt;/label&gt;
                      &lt;input id="idVoiceChannel" type="radio" name="nameMNCChannel" value="Voice" class="inlineRadio" /&gt;
                      &lt;label for="idVoiceChannel"&gt;Call&lt;/label&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
  </code></pre>
  
  <p>Please check code below:</p>
  
  <pre><code>     webBrowser1.Document.GetElementById("DisplayPhoneCountryISO").SetAttribute("value", "BD");
  
          webBrowser1.Document.GetElementById("DisplayPhoneNumber").SetAttribute("value", mobile.Text);
  
  
  
          HtmlElementCollection elc = this.webBrowser1.Document.GetElementsByTagName("input");
          foreach (HtmlElement el in elc)
          {
              if (el.GetAttribute("type").Equals("submit"))
              {
                  el.InvokeMember("Click");
              }
          }
  </code></pre>