Доброго времени суток, не знаю в тот ли раздел пишу, но попытка не пытка
хочу к скрипту что ниже прикрутить gui, с возможностью изменения двух параметров "время срабатывания" и "задержка"
что-то типа такого как во вложении, но все потуги соединить скрипт с gui пока окончились нулевым результатом
Нет ли у глубокоуважаемой публики "горшочка помощи" мне в этом вопросе
хочу к скрипту что ниже прикрутить gui, с возможностью изменения двух параметров "время срабатывания" и "задержка"
что-то типа такого как во вложении, но все потуги соединить скрипт с gui пока окончились нулевым результатом
Нет ли у глубокоуважаемой публики "горшочка помощи" мне в этом вопросе
Код:
#include <Date.au3>
_ScheduleStart_Proc("14:28:11")
Func _ScheduleStart_Proc($sStartTime)
While 1
If _NowTime() = $sStartTime Then Return 1
WEnd
EndFunc
Sleep(800)
Send("{Esc}")
#include <GUIConstants.au3>
#include <Date.au3>
$Form1 = GUICreate("", 189, 222, 338, 125)
$iTimer = GUICtrlCreateInput("00:00:00", 40, 40, 105, 21)
$Timer = GUICtrlCreateLabel("Время", 64, 16, 37, 17)
$iSync = GUICtrlCreateInput("800", 32, 104, 121, 21)
$Sync = GUICtrlCreateLabel("Задержка", 64, 80, 55, 17)
$Button1 = GUICtrlCreateButton("Запуск", 56, 136, 75, 25, 0)
$Button2 = GUICtrlCreateButton("Закрыть", 56, 176, 75, 25, 0)
$Pic1 = GUICtrlCreatePic("", 0, 0, 185, 217, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))
GUISetState(@SW_SHOW)
While 1
Switch GUIGetMsg()
Case $Button2
Exit
Case $Timer
GUICtrlSetData($iTimer, GUICtrlRead($Timer))
Case $Sync
GUICtrlSetData($iSync, GUICtrlRead($Sync))
Case $Button1
$nTimer = GUICtrlRead($iTimer)
$nSync = GUICtrlRead($iSync)
EndSwitch
Wend
_ScheduleStart_Proc("$nTimer")
Func _ScheduleStart_Proc($sStartTime)
While 2
If _NowTime() = $sStartTime Then Return 2
WEnd
Sleep($nSync)
Send("{Enter}")
EndFunc
#include <Date.au3>
$Form1 = GUICreate("", 189, 222, 338, 125)
$iTimer = GUICtrlCreateInput("00:00:00", 40, 40, 105, 21)
$Timer = GUICtrlCreateLabel("Время", 64, 16, 37, 17)
$iSync = GUICtrlCreateInput("800", 32, 104, 121, 21)
$Sync = GUICtrlCreateLabel("Задержка", 64, 80, 55, 17)
$Button1 = GUICtrlCreateButton("Запуск", 56, 136, 75, 25, 0)
$Button2 = GUICtrlCreateButton("Закрыть", 56, 176, 75, 25, 0)
$Pic1 = GUICtrlCreatePic("", 0, 0, 185, 217, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))
GUISetState(@SW_SHOW)
While 1
Switch GUIGetMsg()
Case $Button2
Exit
Case $Timer
GUICtrlSetData($iTimer, GUICtrlRead($Timer))
Case $Sync
GUICtrlSetData($iSync, GUICtrlRead($Sync))
Case $Button1
$nTimer = GUICtrlRead($iTimer)
$nSync = GUICtrlRead($iSync)
EndSwitch
Wend
_ScheduleStart_Proc("$nTimer")
Func _ScheduleStart_Proc($sStartTime)
While 2
If _NowTime() = $sStartTime Then Return 2
WEnd
Sleep($nSync)
Send("{Enter}")
EndFunc