Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Bug on timer, but not deterministic
Message
De
23/10/2003 05:12:50
 
 
À
22/10/2003 06:44:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00840948
Message ID:
00841451
Vues:
23
Fabio,

There's something else that you have yet to discover. I found it a couple of years back. (vfp6sp5)

It may happen that the timer event fires in the middle/midst of a from/grid refresh() (think if you have dynamic...Color with udf's)

Sometimes, within the timer() event this may refer to the object which code is being interrupted.

I have found this to happen on very busy or slow computers when the refresh takes a long time

In order to get around that, you have to skip a cycle.

eg
Timer.Timer()

local obj
obj = this

if( Proper(obj.BaseClass) == Proper('Timer') )
   obj.Enabled  = FALSE	&& stop timer event

   ....

   obj.Enabled = TRUE	&& restore timer event
else
   && skip a cycle
endif
Gregory
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform