Newsgroups : Borland : borland.public.delphi.internet.winsock : 2007 Dec : Re: WebBrowser hook for actual retrieval?
| Subject: | Re: WebBrowser hook for actual retrieval? |
| Posted by: | "Remy Lebeau (TeamB)" (no.spam@no.spam.com) |
| Date: | Sun, 23 Dec 2007 16:59:30 |
"Kevin Killion" <kevin@shsmedia.com> wrote in message
news:kevin-F179A9.10354423122007@newsgroups.codegear.com...
> When a link is clicked and a new page is requested, normally all
> the needed files (html, jpg, etc) are retrieved. I'd like to intercept
> each of those retrievals, grab each file from somewhere else in my
> own code, and then return it back to WebBrowser.
There are plenty of events available (OnBeforeNavigate, OnNavigateComplete,
OnDownloadBegin), but there is no way to replace a file with your own once
the browser tries to download it. In the OnBeforeNavigate event, you can
change the URL for a file, though.
Gambit