Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Disabling all controls on a form
Message
 
 
À
22/01/2002 20:30:51
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00608728
Message ID:
00608899
Vues:
13
>>
>>For the controls on the form
>>Thisform.setall("Enabled", .f.)
>>* or
>>FOR EACH loControl IN Thisform.Controls
>>  IF PEMSTATUS(loControl ,"Enabled",5) && Does the enabled property exist?
>>     loControl.Enabled = .F.
>>  ENDIF
>>ENDFOR
You'll have to add more complicated logic to drill further down if there are containers on the form.
>
>Thanks Sergey, this gets more interesting...
>What control doesn't have an enabled property? Hyperlink is all I could find.

I see that Nadya answered your question already. I would like to add that even one control w/o the property you're accessing/changing will breake the code if you don't check for the property existence.
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform