BHO BeforeNavigete2 and Navigate2 method

S

shoniko

Hi!
I've implemented the BHO for IE. But I have a problem which i can't
solve now. I catch BeforeNavigate2 event. I chenge the parametrs
(urlTogo, PostData), but IE doesn't react on this. It just keeps doing
what it was supposed to do without my BHO.
When I tryied to call Navigate2 method from BeforeNavigate2 it did go
to the redirection page, but didn't catch the post data I passed to
Navigate2 method. Which is very strange to me...
I do this is C#. Here is some code od mine:

private void BeforeNavigate2( object pDisp,
ref object urlObj,
ref object Flags,
ref object TargetFrameName,
ref object PostData,
ref object Headers,
ref bool Cancel )
{


urlObj = urlToGo;
postString = postString.TrimStart('&');
PostData = ASCIIEncoding.ASCII.GetBytes(postString);
Headers = "application/x-www-form-urlencoded" + "\r" + "\n";

}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top