Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Repeating piece of code
Message
De
02/04/2013 09:16:30
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Divers
Thread ID:
01569704
Message ID:
01569718
Vues:
46
>I know that click method does not allow embedded procedures.
>
>But is there any trick to execute a small piece of code inside the method,
>calling it with Do, or other command ?
>
>It would be very useful because when you write inside a procedure it will not work,
>if inside the procedure there are lines as thisform.command1.click, etc.
>
>
>Moises


You can create new methods on the form, which are like procedures, which allow you to call them wherever you like. Something like:
thisForm.myCustomProcedure()
And you add the code you want there, including parameters, by adding a new method to the form (Form menu -> New Method...) and then putting code there.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform