programming tools for Windows applications development
  Home  |   SwiftForth Archive  |   SwiftX Archive  |

Re: Access Violation on Application exit

From: Mike Ghan <mikeghan_at_logix-controls.com>
Date: Wed, 19 Sep 2001 15:10:38 -0700

The example in Win2.F does not execute the :ONSYSEXIT chain. It should
be modified as follows:

: WINMAIN ( -- )
   1 TO APPLICATION DEMO DISPATCHER
   'ONSYSEXIT CALLS \ Execute System Exit Chain
   0 ExitProcess ;

Mike

-----Original Message-----
From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com]On Behalf
Of Bob Nash
Sent: Wednesday, September 19, 2001 2:07 PM
To: 'sftalk_at_forth.com'
Subject: [sftalk] Re: Access Violation on Application exit

I had the same problem once upon a time. I can't remember the exact
cause,
but I think it was a bad word in the ":onsysexit" chain.

-----Original Message-----
From: Robert Dickow [mailto:dickow_at_uidaho.edu]
Sent: Wednesday, September 19, 2001 1:28 PM
To: sftalk_at_forth.com
Subject: [sftalk] Re: Access Violation on Application exit

Thanks for all the tips about Windows message loops and all. Yes, my
program uses what I thought was the canonical method, and in fact
started
out with one of the template programs in the SwiftForth 2.2.2 stuff. My
program worked perfectly under 2.2.2 but broke under 2.2.9, so something
obviously has changed internally. I just don't see where. But I'll look
at
things again to see if the main message loop is still being Dispatched
and
terminated correctly.

Bob

> From: Mike Ghan <mikeghan_at_logix-controls.com>

> Bob, all Windows programs need a message dispatcher loop. A message
> dispatcher loop is started with the SF console program. Standalone
> programs need to start their own message dispatcher loop. The word
> DISPATCHER is a simple dispatcher suitable for many programs. Take a
> look at WINMAIN in Win2.F in the samples directory:
>
> : WINMAIN ( -- )
> 1 TO APPLICATION DEMO DISPATCHER 0 ExitProcess ;
> As for the BYE, I thought it *had* to be used upon exiting the
program.
> To
> clarify, I exit the actual app from a Quit command in a program
window,
>
>...<snip>

----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe sftalk" to listar_at_forth.com
For help with listar commands, send subject "help" to listar_at_forth.com
Archives are located at http://www.forth.com/sftalk -- check them out!
Search the archives! Visit http://www.forth.com/search for details.
Received on Wed Sep 19 2001 - 15:10:44 PDT

This archive was generated by hypermail 2.2.0 : Fri Nov 21 2008 - 03:04:19 PST