Accessing VARIANT FAR* URL string in OnBeforeNavigate2 function. Eek!
Posted on 1998-08-28
The VARIANT data structure is giving me a little trouble, and all I need to do is something (what I thought was)really simple: access the VARIANT FAR* URL that is passed to this function(specifically convert it to a CString or char*, and vice-versa; I'd really like to be able to modify it.)
void CNavThingy::OnBeforeNavigate2Explorer1(LPDISPATCH pDisp, VARIANT FAR* URL, VARIANT FAR* Flags, VARIANT FAR* TargetFrameName, VARIANT FAR* PostData, VARIANT FAR* Headers, BOOL FAR* Cancel)
//All I want to do is access the VARIANT FAR* URL
//but I've had major problems figuring out how to read
//the URL->bstrVal value. ARgh!
AfxMessageBox("Finally! Thank God!");
I've spent way too much time attempting to do this with all the odd VARIANT and BSTR manipulation functions, but I know it's easy. Could anyone help me out?
Thanks in advance.