Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
VFP 8.0 form error - newbie question
hi guys, i have been struggling on what is probabaly a really silly question. i have two forms. formA is the main form and calls form B. all i want to do is set it so that if a user hits the ESC key on formB it simply calls a procedure in a .prg file that closes formB and returns to formA.
formB activate method contains:
ON KEY LABEL ESC DO p_esc
the .prg code looks like this:
PROCEDURE p_esc
formB.release
m_exitreason = 12
RETURN
when i run it and press ESC i get an error on the "formB.release" line. "object formB is not found". for reasons that i don't want to have defend :), i would like to keep the code that closes formB in the .prg procedure file.
i did verify that _screen.activeform.name did indeed return "formB", and i have set the "name" of formB to "formB".
thanks,
n.
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement