Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
On Key Label for a Method
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00126983
Message ID:
00127347
Vues:
21
>In VFP 5.0, I have created a method in a form to copy the value of certain fields to the clipboard memory.
>
>In the Init of the form I am trying to call that method with but I don't know how.
>
>I have tried the following:
>ON KEY LABEL Alt+C DO Thisform.ToClipBoard()
>
>I don't want a button.
>
>Can anyone help?

You cannot use THISFORM in an ON KEY LABEL statement, but there is a workaround. In the Form INIT method, write

PUBLIC oMyForm
oMyForm = ThisForm

In the Form DESTROY method, write

oMyForm = .NULL.
RELEASE oMyForm

and use ON KEY LABEL oMyForm.ToClipBoard()

HTH!
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform