Morgääähn,
ich brauche mal wieder eure Hilfe...folgendes:
In dem kommenden Script soll eine Inputbox eingebunden werden, die während $play=1 immer mit dem Hotkey Strg+o abgerufen werden soll. Bei Eingabe eines Zahlenwertes und OK, soll $time mit $newtime geupdated und auch fürs nächste Mal gespeichert werden. Bei CANCEL soll alter Wert stehen bleiben.
Wäre jemand bereit mir unter die Arme zu greifen???
;~ script for next sample automation
[/autoit][autoit][/autoit][autoit]#include <Misc.au3>
[/autoit][autoit][/autoit][autoit]Dim $play
Dim $time = 20
Dim $exit = 1
$dll = DllOpen("user32.dll")
HotKeySet("^{SPACE}", "starten")
HotKeySet("^{x}", "stoppen")
WinWait("Analyst -", "")
[/autoit][autoit][/autoit][autoit]$manuellerclick = False
While $exit
While $play = 1
if Not $manuellerclick then
WinActivate("Analyst -", "")
ControlSend("Analyst -", "", "AfxOleControl42u2", "^{RIGHT}")
Endif
AdlibRegister("_Countdown", 1000)
While $time > 0 And $play = 1
ToolTip($time)
Sleep(10)
$manuellerclick = False
If _IsPressed("04", $dll) Then
WinActivate("Analyst -", "")
ControlSend("Analyst -", "", "AfxOleControl42u2", "^{RIGHT}")
$manuellerclick = True
ExitLoop
EndIf
WEnd
ToolTip($time)
AdlibUnRegister("_Countdown")
$time = 20
WEnd
Sleep(250)
While $play = 0
ToolTip("")
WEnd
WEnd
[/autoit][autoit][/autoit][autoit][/autoit][autoit]Func _Countdown()
$time -= 1
EndFunc ;==>_Countdown
Func starten()
$play = 1
EndFunc ;==>starten
Func stoppen()
$play = 0
EndFunc ;==>stoppen
DllClose($dll)
[/autoit]Und die Inputbox like this:
[autoit]HotKeySet ("^o", "timeroption")
[/autoit][autoit][/autoit][autoit]Func timeroption()
$newtime = InputBox("Timer-Einstellung", "Bitte gewünschte Sekunden angeben", "", "", 210, 120)
EndFunc
Vielen Dank!
Mel