Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Speeding up DoEvents()
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00142550
Message ID:
00145767
Vues:
30
Rick,

The only thing I've ever used DoDefault() for was to try and minimize missed mouse events that occur during CPU intense processing loops. Or to allow Cancel buttons to interrupt a process. I wonder if actually moving the mouse 1 pixel left/right would help your situation? Does it really hold up an indefinate amount of time (i.e. much longer that the 0.25 seconds DoDefault() takes to execute?) until real mouse motion occurs?

I ran into something where a form of mine that runs in realtime with a timer telling it to refresh (which cascades through about 600 objects on the form) every 10 seconds. I was trying to get a little Shape to become visible at the start of the process and it goes invisible at the end. It serves as a heartbeat indicator assuring the user it's still working and to let them know during the time it's visible the system may miss some of their clicks. I found issuing a thisform.Cls() was needed to get the shape to show up reliably.

>Here's what I'm doing: I have an object that performs a download
>process and fires an OnUpdate 'event'. THis is event is trapped
>in the form (object on the form) and it does a DoEvents to allow
>trappng for a Cancel key hit basically.
>
>Problem is unless the mouse is moved the DoEvents just sits
>there like a READ! Putting the MOUSE code in front of the
>DoEvents appears to do nothing to help the situation. As soon
>as you move the mouse things fly.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform