...programezi calculatorul sa se stinga la orice ora...
nu l-am facut mai complex deoarece vreau sa il dezvoltati voi
#include
Global $set, $time
$font = "Comic Sans Ms"
GUICreate("Auto Cyber Shutdown", 228, 24)
GUISetFont(8.5, 400, 1, $font)
$label = GUICtrlCreateLabel("Shutdown at:", 2, 4, 70, 18)
GUISetFont(8.5, 400, 1, $font)
$set1 = GUICtrlCreateInput("12:59", 72, 2, 50, 20)
$ok = GUICtrlCreateButton("Save", 126, 3, 100, 18)
GUISetBkColor(0x000000)
GUICtrlSetBkColor($label, 0x000000)
GUICtrlSetBkColor($set1, 0x000000)
GUICtrlSetColor($label, 0xFFFFFF)
GUICtrlSetColor($set1, 0xFFFFFF)
GUISetState()
Func check()
If $set = $time Then
GUISetState(@SW_SHOW)
MsgBox(0, "Info", "Dear DUDE:" & @CRLF & "It's time to leave me alone. Bye bye!")
Sleep(4000)
Shutdown(1)
Sleep(100)
Exit
Else
;
EndIf
EndFunc
Func get_time()
$set = GUICtrlRead($set1)
Do
$time = @HOUR & ":" & @MIN
Sleep(100)
Until $set = $time
check()
EndFunc
While 1
$msg = GUIGetMsg()
If $msg = $GUI_EVENT_CLOSE Then ExitLoop
Select
Case $msg = $ok
GUISetState(@SW_HIDE)
get_time()
EndSelect
WEnd