Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dblclick event for the grid control
Message
De
24/04/2003 15:42:16
 
 
À
24/04/2003 14:14:14
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00781234
Message ID:
00781273
Vues:
17
If you have a click method on the same grid control as the doubleclick - it will always get hit first - which can cause doubleclick to not fire if the click takes too long - at least that is what I think happens. In any case, you probably don't want the click to occur when a doubleclick is desired.

I have a click and double click on the same grid control and I use a trick that we had to use in VFP2.6 - back when there were no double clicks.

When you go into the click event - do a loop for a short period of time (_DBLCLICK system variable) to see if another mouse click arrives within that time frame. If it does, then do a return immediately so that doubleclick will fire. If this doesn't fire doubleclick - try doing doubleclick method from withing click using this.parent.doubleclick()

I think you use the INKEY function in a loop for _DBLCLICK seconds...

hope this helps...
I know of no more encouraging fact than the unquestionable ability of man to elevate his life by a conscious endeavor.

Henry Thoreau
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform