ich bin kompletter Neuling was AHK angeht, von daher sorry für zwei vielleicht komplett simple Fragen.
Ich möchte, dass mein Script nach einer bestimmten AFK Zeit alle eingebundenen Platten auswirft. Das klappt soweit erst mal (Script gekürzt):
Code: Select all
Loop,
{
If (A_TimeIdle < 5000) {
Sleep, 1000
} else {
MsgBox, 64, For Your Information, Checkout done at %A_Hour%:%A_Min%
}
}
Code: Select all
#Persistent
Menu, tray, NoStandard
Menu, tray, add, Exit, ExitHandler
OnExit, ExitSub
return
ExitHandler:
ExitApp
return
ExitSub:
if A_ExitReason not in Logoff,Shutdown
{
MsgBox, 64, For Your Information, Exit-Checkout done at %A_Hour%:%A_Min%
}
ExitApp
Loop,
{
If (A_TimeIdle < 5000) {
Sleep, 1000
} else {
MsgBox, 64, For Your Information, Checkout done at %A_Hour%:%A_Min%
}
}
Gibt es außerdem eine Möglichkeit, das Script zu beenden obwohl die MessageBox noch am Display steht? Also eine Art Good-Bye Information zu hinterlassen, obwohl das Script selbst bereits nicht mehr im System ist.
Vielen Dank schon mal für jedwede Hilfe
Slevin