October 30, 2025, 01:06:07 PM

News:

IWBasic runs in Windows 11!


command END

Started by aurelCB, March 20, 2013, 09:34:13 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

aurelCB

I would like to know ..if someone want to explain me...
what is behind command 'END'.
Is this command do complete deleting of variable,pointers and is require PostquitMessage()
api function or not.

LarryMc

from the Help file:
QuoteEND will cause the on-exit list to be iterated. Set a return value by use SETEXITCODE.

When it is encountered it ends the program.

I've used it to fire the subroutines I've set up with ONEXIT that I want executed each time the program ends.
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

aurelCB

Larry i ask this
because i recieve some strange things when i use PostQuitmessage(0) in few my programs.
anyone else have similar problems.
application simply close ...without crush ,with any visible reason ???

LarryMc

I've never used PostQuitMessage.
Maybe this will help you out:
Why is there a special PostQuitMessage function?

Also, I have no idea how/when you are using PostQuitMessage
but the MSDN says
QuoteIndicates to the system that a thread has made a request to terminate (quit). It is typically used in response to a WM_DESTROY message.

LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

aurelCB

Yes standard way to use PostQuitMessage(0) is under WM_DESTROY but looks to
me that cose closing program without reason.
When i don't use @IDDESTROY then program not close without visible reason,
but sometimes hang in memory (visible in TaskManager)...
that is really strange...