title: find active tab or URL or IntPtr windowHandle in IE
body: <p>I have an IEView that has many IEWindows and each IEWindow has an IETab and each IETab has the  window handle of the tab and the url of that tab in it.  </p>
  
  <p>I currently use </p>
  
  <pre><code> WindowStateChanged(uint dwWindowStateFlags, uint dwValidFlagsMask)
  </code></pre>
  
  <p>to know when tabs change.  What I can't figure out is on startup when there is already an IE there in existence, what is the current active tab?  If I could just get the active url, I could find the active tab OR if I could just get the active tab window handle, I could get the active tab.  Maybe I should climb the tree and try to getSelectedTabIndex to determine the active tab as I know my IETabs got added in the exact order that they are in IE which I thought was interesting and probably not a co-incidence.</p>
  
  <p>does anyone know how to either</p>
  
  <ol>
  <li>get the active tab handle OR</li>
  <li>get the active tab's url so I can look up the tab OR</li>
  <li>how I would go about getting the tab control and getting the index of the selected tab</li>
  <li>or perhaps find the focused IntPtr handle since the window at this time is coming into focus and hopefully the tab is considered the thing in focus?</li>
  </ol>
  
  <p>thanks,
  Dean </p>