Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to send a variable to form?
Message
De
08/09/1999 13:57:46
 
 
À
07/09/1999 17:34:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00262206
Message ID:
00262495
Vues:
19
>I have a code to filter the record from the table. Only selected record, I want to plot the graph in the form.
>
>How to pass the variable from the code to the form?
>

If you put a PARAMETER or LPARAMETER statement in the Initi method of the form, you can pass the value as an argument on the command line. If the value is needed outside of the Init, you'll want to create a form property and save it there, since the parameter will pass out of scope when the Init terminates.

To pass a parameter on the DO FORM command line:
cSomeKeyValue = <i> the value you want to pass</i>

DO FORM MyForm WITH cSomeKeyValue


*
*Init of MyForm - I assume you've defined a form property cMyKey
LPARAMETER tcParamValue
IF PCOUNT() > 0
   this.cMyKey = tcParamValue
ELSE
   this.cMyKey = NULL
ENDIF
>Thanks
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform