SniperSA Posted October 14, 2006 Share Posted October 14, 2006 I want to first find out how to get the program so lets say the user types in the input box i want the program to run notepad.exe and type the input. So how could i put $msg = $input and tell it to type what is in the box? Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted October 14, 2006 Share Posted October 14, 2006 look at Guictrlread, and the run function the help file Link to comment Share on other sites More sharing options...
SniperSA Posted October 14, 2006 Author Share Posted October 14, 2006 ok well first i tested the GUICtrlRead and i told it to send input's data to a notepad, that worked. but now i was trying to make a GUICtrlCreateCombo and i put in my data. so when i test to see if it reads whats in the combo box and it says "3" #include <GUIconstants.au3> GUICreate("Script Select",200,200) $1337 = GUICtrlCreateCombo("AIM Send",0,0) GUICtrlSetData(-1,"Check Email|Check Myspace|Find X,Y|Starcraft Start") $ok = GUICtrlCreateButton("Run Script",0,20) GUISetState(@SW_SHOW) While 1 $msg = GUIGetMsg() Select case $msg = $ok GUICtrlRead($1337) Msgbox(0,"Test",$1337) Case $msg = $GUI_EVENT_CLOSE ExitLoop EndSelect WEnd Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted October 15, 2006 Share Posted October 15, 2006 something like this #include <GUIconstants.au3> GUICreate("Script Select",200,200) $1337 = GUICtrlCreateCombo("AIM Send",0,0) GUICtrlSetData(-1,"Check Email|Check Myspace|Find X,Y|Starcraft Start") $ok = GUICtrlCreateButton("Run Script",0,20) GUISetState(@SW_SHOW) While 1 $msg = GUIGetMsg() Select case $msg = $ok Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", GUICtrlRead($1337) ) Case $msg = $GUI_EVENT_CLOSE ExitLoop EndSelect WEnd Link to comment Share on other sites More sharing options...
SniperSA Posted October 15, 2006 Author Share Posted October 15, 2006 well, i see that it works but lets say when AIM Send is selected i would want it to run a code, as an example you could use Msgbox(0,"AIM Send","Test") Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted October 15, 2006 Share Posted October 15, 2006 what you mean run a code? like a program, if so check out the Run() command in the helpfile Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now