Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Checking for existence of a control
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00701952
Message ID:
00701981
Vues:
22
This message has been marked as the solution to the initial question of the thread.
Well if you're looking for the existences of a control you must have a container class of some sort. So from inside the container class or form you can reference controls by name as follows:

THIS - being the container or form
IF VARTYPE(THIS.txtName)="O"
  THIS.txtName.Value = "William"
ELSE
  MESSAGEBOX("Control txtName does not exist!")
ENDIF
>I guess it never escaped me because I never heard of PEMstatus. Reminds me of the Pemigewasset river up here in NH country. Anyway, still having trouble becasue if a control doesn't even exist, I cannot even refer to it.
>Or am I not comprehending correctly.
>
>
>>>It escapes me the syntax for checking for the existence of a control like a commandbutton. If...............?
>>>
>>>-TB
>>
>>How about
>>
>>IF VARTYPE(THIS.oControlName)="O"
>>
>>or
>>
>>IF TYPE("THIS.oControlName")="O"
>>
>>or
>>
>>IF PEMSTATUS(THIS,"oControlName",5)
Heavy Metal Pedal - click with care
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform