Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Difficulty with browser control
Message
From
03/10/2008 12:52:31
 
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01352564
Message ID:
01352596
Views:
30
>Hi Alex,
>
>>The navigator is timing out, even when I increase time to 8 seconds, but only sometimes (often).
>>
>>What could be causing the problem? Maybe some properties are set wrong? I created the class some time ago and haven;t used it much.
>
>I have had bad luck with this type of loop waiting for the WebBrowser control:
>
>
>>>>	DO WHILE toBrowser.ReadyState # lnReadyState AND lnX < lnMilliSeconds
>>>>		DOEVENTS
>>>>		lnX = lnX + 1
>>>>		Sleep(1)
>>>>	ENDDO
>
>
>Even the DOEVENTS / Sleep combination do not seem to be enough to allow the control to do it's job. But stepping through the code does. That's what makes this fustrating to debug.
>
>I would try one of these 3 things:
>
>1) Change your DOEVENTS to DOVENTS FORCE
>2) Make sure _VFP.AutoYield is set to .T.
>3) Don't use a loop to wait for the browser to finish, instead hook into the NavigateComplete2 event. This is similar to a CallBack and is the preffered methodology for dealing with Asynchronous processes.
>
>I hope this helps,

It feels better just knowing that I am not the only one with this problem. _VFP.AutoYield is already .T.. I am going to try suggestion 3 and report back

Thanks.
Previous
Reply
Map
View

Click here to load this message in the networking platform