Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Multiple Firings of Valid and When Events
Message
De
30/12/1997 11:43:20
 
 
À
29/12/1997 14:54:33
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00068242
Message ID:
00068425
Vues:
24
>>>When using a Chechbox control, if the user double clicks the control, the Valid method fires twice. Once before the Double click and once after. I got around this by having the double click method change the control comment to "DC" then the first thing the Valid method does is check to see if the comment is "DC". If it is, the Valid method changes the comment to blank and returns else it does what ever. This seems a little clummsy. Do you have a better idea?
>>Robert,
>>
>>How about taking your code out of the Valid and putting it in the interactivechang?
>
>Thanks,
>
>Good idea, but, I have a varible bound to the control and the bound varible doesn't update until the valid event. Try this,
>
>Make a form with a checkbox control then in the click/interactivechange/valid/when/dblclick methods enter the following:
>
>activate screen
>counter = counter+1
>? program(),this.value,test1,counter
>
>set the controlsource equal to test1
>
>save the form then before running at the command prompt set test1 = false and counter = 0. Run the form, then click and dblclick on the check box. You will see my problem.

I tried it. Looks like putting "nodefault" in the dblclick() event keeps the valid from executing twice.

Bill
Bill Morris
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform