Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Control form instance activated by menu
Message
De
26/02/2003 23:42:51
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de menu & Menus
Divers
Thread ID:
00758519
Message ID:
00758577
Vues:
26
>I'm using Define Bar ... Prompt thisform.caption to add open instances of a form to the menu. The caption includes info to identify the record displayed in the form and changes each time the form is requeried. When the user makes a selection, the On Selection ... needs the window name for the Activate Window command. I can't use the form name in this situation because it is not unique. How can I get the window name?

One approach is to append an instance number to each form's title e.g. MyForm:1, MyForm:2, etc. Some frameworks with their own form manager classes do this.

You might also be able to work with the VFP Forms collection e.g. if the user picks the second of 3 instances of FormX from the menu, parse the Forms collection to find the desired form instance.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform