Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
WebBrowser control reactivates form
Message
De
20/07/2011 16:42:05
Joel Leach
Memorial Business Systems, Inc.
Tennessie, États-Unis
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Titre:
WebBrowser control reactivates form
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Divers
Thread ID:
01518702
Message ID:
01518702
Vues:
100
I'm using the IE WebBrowser control via the _webbrowser4 class in the FFC. I am using a vfps:// script to open a modeless VFP form, which works well, except the form hosting the browser control reactivates itself afterwards. I want the form I just launched to have focus, not the browser control. I have traced the code in the _webbrowser4 class, but I don't see any explicit Activate statement. Any idea what's going on and how to fix it?

UPDATE: I tested on a base VFP form using the stock web browser control (no wrapper), and I get the same behavior. Here's the code I have in BeforeNavigate2():
*** ActiveX Control Event ***
LPARAMETERS pdisp, url, flags, targetframename, postdata, headers, cancel

If url = "vfps"
	Cancel = .t.
	Do form MyForm
EndIf

Return DoDefault(pdisp, url, flags, targetframename, postdata, headers, cancel)
Thanks.
Joel Leach
Microsoft Certified Professional
Blog: http://www.joelleach.net
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform