Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Close form with close button instead of X
Message
De
08/02/2010 10:55:53
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01448035
Message ID:
01448068
Vues:
76
somebody provided me following codes, but those do not work

Pleaes modify


Maybe bindevent can help you.
The idea is to write your own handler for queryunload and bind to your forms.

*
* in your main.prg add handler to each form
*
for each m.form in _screen.forms
do myHandler with m.form
endfor


*
* myHandler.prg
*
para oForm
private o
m.o=createobject("myHandler")
=addproperty(m.oForm,"__handler", m.o)
=bindevent(m.oForm,"queryunload",m.o,"doQueryUnload")

define class myHandler as session
datasession=1

function doQueryUnload
=messagebox("Please press close button to exit",_screen.ActiveForm.caption)
nodefault
enddefine
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform