 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
Marc Guest
|
Posted: Sat Jan 19, 2008 2:22 pm Post subject: Countdown in MsgBox |
|
|
Hello,
I would like to have a countdown in my MassageBox that indicates the remaining time until timeout.
The code just starts my calendar, so its not very important, just curiosity.
| Code: | MsgBox, 292, Kalender?, Soll der Kalender gestartet werden?, 5
IfMsgBox Yes
Run, C:\Program Files (x86)\Rainlendar2\Rainlendar2.exe, C:\Program Files (x86)\Rainlendar2.
else
ExitApp |
Thanks
Marc |
|
| Back to top |
|
 |
SKAN
Joined: 26 Dec 2005 Posts: 6264
|
Posted: Sat Jan 19, 2008 2:58 pm Post subject: |
|
|
| Code: | Secs := 20
SetTimer, CountDown, 1000
MsgBox, 1, System Shutdown in 20 seconds, Allow Auto Shutdown?, %Secs%
SetTimer, CountDown, Off
/*
IfMsgBox Ok
Shutdown, 8
*/
Return
CountDown:
Secs -= 1
WinSetTitle, System Shutdown in,, System Shutdown in %Secs% seconds
Return |
 |
|
| Back to top |
|
 |
Marc Guest
|
Posted: Sat Jan 19, 2008 4:20 pm Post subject: Thanks |
|
|
Thats it, Thanks a lot!  |
|
| Back to top |
|
 |
Mustang
Joined: 17 May 2007 Posts: 415 Location: England
|
Posted: Sun Jan 20, 2008 4:09 am Post subject: |
|
|
| I could do with a MassageBox |
|
| Back to top |
|
 |
Murp|e
Joined: 12 Jan 2007 Posts: 261 Location: Norway
|
Posted: Mon Jan 21, 2008 2:41 pm Post subject: |
|
|
| Although a massagebox sounds great, if you don't want to use the WinSetTitle method provided, you could use a simple GUI instead of the massagebox. In which case you would replace WinSetTitle with controlsettext. |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|