ATL如何获得当前IE地址栏的句柄???

whispers 2006-08-03 09:37:32
m_spWebBrowser2->get_HWND((long *)&pHWND);
连当前IE的句柄也取不到?
...全文
225 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
kaixuan1901 2006-08-10
  • 打赏
  • 举报
回复
HWND m_hwndOther = FindWindowExA(NULL,NULL,"IEFrame",NULL);
if(m_hwndOther == NULL)
{
m_hwndOther = FindWindowExA(NULL,NULL,"CabinetWClass",NULL);
if(m_hwndOther == NULL)
{
m_hwndOther = FindWindowExA(NULL,NULL,"ExploreWClass",NULL);
}
}
if(m_hwndOther == NULL)
return NULL;

m_hwndOther = FindWindowExA(m_hwndOther,NULL,"WorkerW",NULL);
if(m_hwndOther == NULL)
return NULL;

m_hwndOther = FindWindowExA(m_hwndOther,NULL,"ReBarWindow32",NULL);
if(m_hwndOther == NULL)
return NULL;

return FindWindowExA(m_hwndOther,NULL,"ComboBoxEx32",NULL);
whispers 2006-08-04
  • 打赏
  • 举报
回复
HWND pHWND;
pomelowu 2006-08-03
  • 打赏
  • 举报
回复
pHWND 是什么?HWND *?

3,245

社区成员

发帖
与我相关
我的任务
社区描述
ATL,Active Template Library活动(动态)模板库,是一种微软程序库,支持利用C++语言编写ASP代码以及其它ActiveX程序。
社区管理员
  • ATL/ActiveX/COM社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧