我知道可以用下面方式遍历所有打开的IE窗口.
SHDocVw::IShellWindowsPtr m_spSHWinds;
if (m_spSHWinds == NULL)
{
if (m_spSHWinds.CreateInstance(__uuidof(SHDocVw::ShellWindows)) != S_OK)
{
MessageBox("Failed");
CoUninitialize();
EndDialog(1);
}
}
if (m_spSHWinds)
{
int n = m_spSHWinds->GetCount();


for (int i = 0; i < n; i++)
{
                  ...................
                }
        }
怎么得到当前处于活动状态的窗口呢,比如我打开发很多个IE,怎么得到我正在浏览的IE窗口?