Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dealing with memo field
Message
De
01/12/2003 22:09:02
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Dealing with memo field
Divers
Thread ID:
00854887
Message ID:
00854887
Vues:
55
In our framework, the Escape key is launching the close sequence of the active form. All that works well. But, on the administration options of the application, soemtimes, the admin will double click on a memo field from a grid to open its content. At that level, if the Escape key is done, this will trigger an error as this is not interpreted as a _screen.ActiveForm.

This is what we have in the code to launch the closing sequence:
IF _screen.ActiveForm.QueryUnload()
   IF FormIsObject()
      _screen.ActiveForm.Release()
   ENDIF
ENDIF
How can I detect that I am in a memo field?

When I first try to enhance that part, I verified if _screen.ActiveForm was an object. Even at the memo field level, it is. So, that verification was not good. I then tried with the following:
IF NOT PEMSTATUS(_screen.ActiveForm,'QueryUnload',5)
   RETURN
ENDIF
So, from the memo field, this will be used. Now, I just need to find a way to have it closed. As it is now, it will simply return and do nothing. So, the memo field window will remain opened.

The entire code in the close sequence, which is triggered by the Escape key, is the following:
IF NOT PEMSTATUS(_screen.ActiveForm,'QueryUnload',5)
   RETURN
ENDIF

IF _screen.ActiveForm.QueryUnload()
   IF FormIsObject()
      _screen.ActiveForm.Release()
   ENDIF
ENDIF
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform