🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #12880

Re: Application notification on Machine restart or shutdown

#12880
From: Hern�n Tornielli
Date: Wed, 12 Nov 2003 01:44
19 lines
1880 bytes
"Remy Lebeau (TeamB)" <gambit47.no.spam@no.spam.yahoo.com>
escribi� en el mensaje news:3fb1820b$1@newsgroups.borland.com...

> You need to finish your cleanup *before* returning from WM_ENDSESSION.
> WM_QUERYENDSESSION notifies you that a shutdown/logout is about to
> occur but has not happened yet.  WM_ENDSESSION, on the other hand,
> indicates that the shutdown/logout *will* occur, and can happen at any
> time after you finish processing the message.

Let's say that at shutdown/logout, I need to do something that would take
a couple of minutes to finish, and am concerned for whether or not
Windows will wait me.
Do you know if it is better to do that lengthy operation before returning
from WM_QUERYENDSESSION or WM_ENDSESSION?
Should I call Application->ProcessMessages() during that operation?

Regards,

Hernan Tornielli
Technical Details
Message-ID: <3fb19037$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3fb15541@newsgroups.borland.com> <3fb15956$1@newsgroups.borland.com> <3fb17fcd@newsgroups.borland.com> <3fb1820b$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10cc67,c54773486c2a14af
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-11-11 18:09:24 PST
From: "Hern�n Tornielli" <hernan@nospam.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3fb15541@newsgroups.borland.com> <3fb15956$1@newsgroups.borland.com> <3fb17fcd@newsgroups.borland.com> <3fb1820b$1@newsgroups.borland.com>
Subject: Re: Application notification on Machine restart or shutdown
Date: Tue, 11 Nov 2003 22:44:15 -0300
Lines: 24
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 200.59.37.15
Message-ID: <3fb19037$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1068601399 200.59.37.15 (11 Nov 2003 17:43:19 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail