mshtml - autobrowsing, and authentication

  • Thread starter Thread starter Oliver
  • Start date Start date
O

Oliver

hi - my foray into 'autobrowsing' using mshtml etc is going ok - but
rather slow (partly) because I'm struggling to find documentation.

anyone have any idea how to achieve authentication in an automated
way?

I have automatically navigated to a page in IE, automatically clicked
a link, but am stuck when the browser challanges for credentials. I
was hoping for a 'OnBasicAuthChallange' event, or some
username/password area of the MSHTML document I could set...

I guess I *could* try navigating to url like this:
http://user:[email protected] - but there must be another way....

more broadly - anyone have hints on where I might find documentation
for this sort of stuff...

thanks all,
regards,
Oliver.
 
Oliver,

When you are calling the Navigate method for the WebBrowser, you can
pass the headers for the authenication as the last parameter.

Using MSHTML, you can use the IAuthenticate interface (defined in COM)
to be called when you come across an authenticated resource. There is an
example of how to do this, but it uses C. However, it shows how to do it
overall using the appropriate interfaces, which you can then implement in
..NET. The article is titled "SAMPLE: Progress Uses IAuthenticate to Bind to
Secured Web Page" and can be found at (watch for line wrap):

http://support.microsoft.com/default.aspx?scid=kb;en-us;156905

Hope this helps.
 
Back
Top