Here's a script:
my problem?
Well when u press ok i want to get the stuff saved :o
(which it doesn't do atm)
my problem?
Well when u press ok i want to get the stuff saved :o
(which it doesn't do atm)
Quote:
#include <GUIConstantsEx.au3>
Hotkeyset("{F1}", "_send1")
Hotkeyset("{F2}", "_send2")
Hotkeyset("{F3}", "_send3")
Hotkeyset("{F4}", "_send4")
Hotkeyset("{F5}", "_send5")
Hotkeyset("{F6}", "_send6")
Hotkeyset("{F7}", "_send7")
Hotkeyset("{F8}", "_send8")
Hotkeyset("{F9}", "_send9")
Hotkeyset("{F10}", "_send10")
Hotkeyset("{F11}", "_send11")
Hotkeyset("{ESC}", "_exit")
global $var
global $file1
global $file2
global $file3
global $file4
global $file5
global $file6
global $file7
global $file8
global $file9
global $file10
global $file11
Opt('MustDeclareVars', 1)
Example()
Func Example()
Local $Button_1, $Button_2, $msg
Local $file1, $btn, $msg
Local $file2, $btn, $msg
Local $file3, $btn, $msg
Local $file4, $btn, $msg
Local $file5, $btn, $msg
Local $file6, $btn, $msg
Local $file7, $btn, $msg
GUICreate("Option Menu, Made by Stefan", 590, 443, 194, 131) ; will create a dialog box that when displayed is centered
GUICtrlCreateLabel("Add the macro's urself: ", 16, 8, 114, 17)
GUICtrlCreateLabel("1) Select the Macro's u want to use", 152, 8, 171, 17)
GUICtrlCreateLabel("2) Type the wanted texts in the input boxes!", 152, 24, 210, 17)
GUICtrlCreateCheckbox("Macro 1 (Hotkey : F1)", 16, 32, 129, 25)
$file1 = GUICtrlCreateInput("", 16, 56, 513, 21)
GUICtrlCreateCheckbox("Macro 2 (Hotkey : F2)", 16, 88, 177, 17)
$file2 = GUICtrlCreateInput($file2, 16, 104, 513, 21)
GUICtrlCreateCheckbox("Macro 3 (Hotkey : F3)", 16, 136, 177, 25)
$file3 = GUICtrlCreateInput("", 16, 160, 513, 21)
GUICtrlCreateCheckbox("Macro 4 (Hotkey : F4)", 16, 192, 129, 25)
$file4 = GUICtrlCreateInput("", 16, 216, 513, 21)
GUICtrlCreateCheckbox("Macro 5 (Hotkey : F5)", 16, 248, 121, 25)
$file5 = GUICtrlCreateInput("", 16, 272, 513, 21)
GUICtrlCreateCheckbox("Macro 6 (Hotkey : F6)", 16, 304, 169, 25)
$file6 = GUICtrlCreateInput("", 16, 328, 513, 21)
GUICtrlCreateCheckbox("Macro 7 (Hotkey : F7)", 16, 360, 129, 25)
$file7 = GUICtrlCreateInput("", 16, 384, 513, 21)
$Button_1 = GUICtrlCreateButton("ok", 88, 408, 153, 25)
$Button_2 = GUICtrlCreateButton("Cancel", 320, 408, 145, 25)
GUISetState() ; will display an dialog box with 2 button
; Run the GUI until the dialog is closed
While 1
$msg = GUIGetMsg()
Select
Case $msg = $GUI_EVENT_CLOSE
ExitLoop
Case $msg = $Button_1
$var = MsgBox( 4, "Option Menu, Made by Stefan", "Oké Ur Macro has been saved")
if $var = 6 Then
msgbox(1, "Option Menu, Made by Stefan", "All Credits go to stefan :p")
EndIf
if $var = 7 Then
msgbox(0, "Option Menu, Made by Stefan", "You Pushed no, the script won't be executed")
exit
EndIf
Case $msg = $Button_2
MsgBox(0, 'Canceled', "You Canceled this application, the script won't be executed") ; Will demonstrate Button 2 being pressed
Exit
EndSelect
WEnd
EndFunc ;==>Example
Func _send1()
send("{enter}")
sleep(100)
Send($file1)
sleep(100)
send("{enter}")
endfunc
Func _send2()
Send($file2)
endfunc
Func _send3()
send("{enter}")
sleep(100)
Send($file3)
sleep(100)
send("{enter}")
endfunc
Func _send4()
send("{enter}")
sleep(100)
Send($file4)
sleep(100)
send("{enter}")
endfunc
Func _send5()
send("{enter}")
sleep(100)
Send($file5)
sleep(100)
send("{enter}")
endfunc
Func _send6()
send("{enter}")
sleep(100)
Send($file6)
sleep(100)
send("{enter}")
endfunc
Func _send7()
send("{enter}")
Send($file7)
send("{enter}")
endfunc
Func _send8()
send("{enter}")
sleep(100)
Send($file8)
sleep(100)
send("{enter}")
endfunc
Func _send9()
send("{enter}")
sleep(100)
Send($file9)
sleep(100)
send("{enter}")
endfunc
Func _send10()
send("{enter}")
sleep(100)
Send($file10)
sleep(100)
send("{enter}")
endfunc
Func _send11()
send("{enter}")
sleep(100)
Send($file11)
sleep(100)
send("{enter}")
endfunc
func _exit()
exit
endfunc