Delphi Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreDelphi Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 13th, 2005, 12:44 AM
Delphitus Delphitus is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Posts: 21 Delphitus User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 37 m
Reputation Power: 0
OnCloseQuery and system shutdown

Hello, I have my app do extra stuff before it shuts down by using OnCloseQuery, but it slows down the shutdown of the computer and I want to make sure that if the users wants his computer to shutdown my program will turn off right then but if he just clicks x it'll stay open for a bit longer. Similar to apps that when x is clicked minimize to the sys tray, but quit when the system is shutdown. Have any suggestions?

Reply With Quote
  #2  
Old March 14th, 2005, 11:22 AM
Mustang_v Mustang_v is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2005
Posts: 43 Mustang_v User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 30 m 30 sec
Reputation Power: 4
Friend....you may use the shutdown messages:

WM_QUERYENDSESSION
This one is sent by WINDOWS to all running programs if every program response was something different of 0, WINDOWS send de next message.

WM_ENDSESSION
This message represents that windows already start the shutdown process.

Comments on this post
HappyDev disagrees: Very helpful answer, thanks!

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreDelphi Programming > OnCloseQuery and system shutdown


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway
Stay green...Green IT