Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Returning a value from a form
Message
De
23/08/2004 19:31:16
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00935781
Message ID:
00935784
Vues:
25
This message has been marked as the solution to the initial question of the thread.
>Hi all, I have this form class which I instantiate this way:
>
>
>  SET CLASSLIB TO calendario ADDITIVE
>
>  Thisform.Calendario=CREATEOBJECT("Calendario")
>  Thisform.Calendario.Left= This.Left+This.Width+Thisform.Left+10
>  Thisform.Calendario.Top = This.Left+This.Width+Thisform.Top
>  Thisform.Calendario.Show
>
>
>Now, how can I return a value from this form. It's a modal form.
>
>Thanks in advance
>
>Enmanuel

You can do something like this:

In your class, add aproperty for the return val, say .Retval.

Instead of closing your form class, hide your form, and let the calling program retrieve the property and close the form.

In your class,
thisform.Hide()
And in your calling program,
thisform.Calendario.Show()
dRetDate = thisform.Calendario.RetVal
thisform.Calendario.Release()
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform