thibeaz Posted August 27, 2008 Share Posted August 27, 2008 Here is my code(by the way this is a simple launcher for the sdl version of VisualBoyAdvance)Could anybody help me please#NoTrayIcon #include <GUIConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 350, 79, 193, 125) $Button1 = GUICtrlCreateButton("Button1", 8, 8, 75, 25, 0) $Input1 = GUICtrlCreateInput("Input1", 88, 8, 249, 21) $Button2 = GUICtrlCreateButton("Button2", 8, 40, 331, 25, 0) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 $File = FileOpenDialog("Open Rom", @ScriptDir, "GBA (*.gba;*.zip)") GuiCtrlSetData($Input1, $File) Case $Button2 ShellExecute(@ScriptDir + 'App\VisualBoyAdvance\vba.exe' + $Button1) EndSwitch WEnd Link to comment Share on other sites More sharing options...
Richard Robertson Posted August 27, 2008 Share Posted August 27, 2008 (edited) ShellExecute(@ScriptDir + 'App\VisualBoyAdvance\vba.exe' + $Button1) This line is a problem. I don't know what you intended to do here, but I know that won't work. Did you perhaps mean to use & to combine strings? + is only for addition of numbers and will not join strings. Also, you'll need spaces and a slash. And I think that $Button1 was supposed to be $File. ShellExecute(@ScriptDir & '\App\VisualBoyAdvance\vba.exe ' & $File) Edited August 27, 2008 by Richard Robertson Link to comment Share on other sites More sharing options...
thibeaz Posted August 27, 2008 Author Share Posted August 27, 2008 (edited) Thanks Mate I just found that out my self XD it's been sometime since I last used Autoit (mostly been working with delphi which does use the + sign XD), Really thanks a lot though man Edited August 27, 2008 by thibeaz Link to comment Share on other sites More sharing options...
Richard Robertson Posted August 27, 2008 Share Posted August 27, 2008 It happens. I've done it before too. 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