Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Default button behavior
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Titre:
Default button behavior
Divers
Thread ID:
00618828
Message ID:
00618828
Vues:
53
In my application, I have a single form which contains a pageframe where the bulk of data entry is done. I have a command button on the main form which is hidden. I have programmed this button with a case structure to behave in a specific manner depending on which page frame is active when the user hits the {ENTER} key. Usually, this behavior is to activate a command button on the tab which populates the screen with data. The case structure in the default button's Click() property is basically like the following

DO CASE
CASE PageFrame.ActivePage = 1
PageFrame.Page1.cmdDisplay.Click()
CASE Pageframe.ActiveaPage = 2
Pageframe.Page2.cmdDisplay.Click()
----- etc
ENDCASE

What I need to happen is when the ActivePage is the first tab, hitting ENTER does nothing. For the other tabs hitting enter should fire the default behavior. I have tried to set and rest the default button's Default property from .T. to .F. but when I trace with the debugger, the property resets to .T. at some point I have not been able to determine, but before my code resets the property to .T.

What might I be missing? TIA
Richard Bates
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform