3,245
社区成员
发帖
与我相关
我的任务
分享
if (pMsg->message == WM_LBUTTONDOWN)
{
int pointx = 0,pointy = 0;
pointx = pMsg->pt.x;
pointy = pMsg->pt.y;
CComQIPtr < IHTMLDocument2,&IID_IHTMLDocument2 > spDoc =m_web.get_Document();
CComPtr <IHTMLElement> pEment;
BSTR bst;
CString strUrl;
spDoc->elementFromPoint(pointx,pointy,&pEment);
pEment->get_innerText(&bst);
strUrl = bst;
MessageBox(strUrl);
}