Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Does quit (in a form) fire unload?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
SAMBA Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01059261
Message ID:
01059412
Views:
9
Thank you both! I appreciate it!


>Joe,
>I now realise what happens. READ EVENTS is AFTER return .f. of the form init.
>
>
>oForm = CREATEOBJECT("Form1")
>READ EVENTS && That line is AFTER return .f. of the form and Unload Event of the form. So CLEEAR EVENTS has no effects
>
>**************************************************
>*-- Form:         form1 (d:\works\traff\tte.scx)
>*-- ParentClass:  form
>*-- BaseClass:    form
>*-- Time Stamp:   10/14/05 10:41:01 PM
>*
>DEFINE CLASS form1 AS form
>
>
>    DoCreate = .T.
>    Caption = "Form1"
>    Name = "Form1"
>
>
>    PROCEDURE Init
>        RETURN .f.
>    ENDPROC
>
>
>    PROCEDURE Unload
>        WAIT WINDOW "Unload" NOWAIT
>        CLEAR EVENTS
>    ENDPROC
>
>
>ENDDEFINE
>*
>*-- EndDefine: form1
>**************************************************
>
>
>
>Chane it to:
>
>oFOrm = CREATEOBJECT("Form1")
>
>
>**************************************************
>*-- Form:         form1 (d:\works\traff\tte.scx)
>*-- ParentClass:  form
>*-- BaseClass:    form
>*-- Time Stamp:   10/14/05 10:41:01 PM
>*
>DEFINE CLASS form1 AS form
>
>
>    DoCreate = .T.
>    Caption = "Form1"
>    Name = "Form1"
>
>
>    PROCEDURE Init
>        *****
>        Do whaever you want to to
>        IF some_condition
>           RETURN .f.
>        ENDIF
>        READ EVENTS
>    ENDPROC
>
>
>    PROCEDURE Unload
>        WAIT WINDOW "Unload" NOWAIT
>        CLEAR EVENTS
>    ENDPROC
>
>
>ENDDEFINE
>*
>*-- EndDefine: form1
>**************************************************
>
Previous
Reply
Map
View

Click here to load this message in the networking platform