title: VBA Cannot get the Option via select drop down to work
body: <p>I am trying to set the value for a drop down box and it shows a blank which is not even an option. </p>
  
  <p>Here is the HTML snip-it: (NOTE: internal website so I cant give URL or too much)</p>
  
  <pre><code>&lt;select id="entNo" name="entNo" style="width:75px"&gt;
    &lt;option selected="selected" value="All"&gt;All&lt;/option&gt;
    &lt;option value="650101"&gt;650101&lt;/option&gt;
    &lt;option value="66"&gt;66&lt;/option&gt;
  </code></pre>
  
  <p>Here is the function for it.</p>
  
  <pre><code>    function requestEntities()
    {
        var ele = document.getElementById('entNo');
        if (ele) {
            ele.options.length = 0;
            ele.options[0] = new Option('All');
            ele.disabled = true;
            ele = document.getElementById('divNo');
            if (ele) {
                var i = ele.selectedIndex;
                var div = ele.options[i].value;
                sendHttpRequest('http://example.com/cgi-bin/wspd_cgi.sh/WService=wslive//wpr/entityList.r?div=' + div);
            }
        }
    }
  </code></pre>
  
  <p>The vba code I am using is this:</p>
  
  <pre><code>Set objCollection = ie.document.getElementsByTagName("select")
      'Debug.Print objCollection.Length
  
      i = 1
      While i &lt; objCollection.Length        'Loop to locate and change the fields with proper data using the "select" tags
          Debug.Print objCollection(i).Value
          If objCollection(i).Name = "entNo" Then
              If ecode &lt;&gt; "" Then
              Debug.Print objCollection(i).Value
                  objCollection(i).Value = ecode
              End If
  
          ElseIf objCollection(i).Name = "curStatus" Then
              objCollection(i).Value = "Open"
  
          ElseIf objCollection(i).Name = "opStatus" Then
              objCollection(i).Value = "All"
  
  
          End If
              i = i + 1
      Wend
  </code></pre>
  
  <p>I can't give more as this is for work. I have exhausted google searches.<br>
  One other thing that is strange is that it will work when I single step. It just will not work otherwise. 
  Any suggestions would be greatly appreciated.</p>