Information générale
Catégorie:
Gestionnaire d'écran & Écrans
What Bruce has replied is correct, you need an object reference. In the case of forms, the NAME clause permits the establishment of what is sometimes called a "linked variable" but you can call it an object reference.
DO FORM X NAME OX WITH "This is a test" && requires Parameter or Lparameter
&& in Init() event procedure code
&& to accept the parameter
&&
&& Linked clause may be something
&& you want to try since it can
&& close the form by: Release ox
If VarType( m.ox ) = "O" && good idea to test for 'object' type
ox.Caption = "Hurrah, ox works!"
else
=messageBox( "What happened, those guys at UT said this would work" )
endif
NOTE it is a good idea to follow some naming convention, Hungarian, Polish, Irish, whatever -- just keep the variable names distinct, since some people do name forms that maintain tables the same name as the alias, which considering the syntax of VFP makes it tough to differentiate between and among object references and aliases.
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement