Click to See Complete Forum and Search --> : Web Browser Control - Help with opening link on another Control in different form


HerickPaiva
May 14th, 2001, 02:40 PM
Hi,

I have two forms, each one with a web Browser control. I would like to be able to click on a link located on control A on Form1 to open the link on Control B on form2. Is it possible??

Herick

Sudeep Nayak
May 15th, 2001, 04:04 AM
In form1, having control1, say you have webbrowser1,
In form2, having control1, say you have webbrowser1,

Insert the following:

private Sub WebBrowser1_BeforeNavigate2(byval pDisp as Object, URL as Variant, FLAGS as Variant, TargetFrameName as Variant, PostData as Variant, Headers as Variant, Cancel as Boolean)
set pDisp = form2.WebBrowser1.object
End sub




That must help.

coolbiz
May 15th, 2001, 08:13 AM
Wondering if you actually have to set the Cancel variable to 1 in the Form1 WebBrowser1 control so that it does not load the same page as Form2 WebBrowser1 :)

-Cool Bizs