myxomatosii Posted March 11, 2009 Posted March 11, 2009 I don't understand why this won't run firefox when I can just type "firefox.exe" into windows and it does it fine. Run("firefox.exe",@ProgramFilesDir&"\Mozilla Firefox")
BrettF Posted March 11, 2009 Posted March 11, 2009 2nd Param is NOT the folder where the first param is located. Really, please search for that... Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
myxomatosii Posted March 11, 2009 Author Posted March 11, 2009 2nd Param is NOT the folder where the first param is located. Really, please search for that...I was born near a large cache of plutonium, in my asbestos house under electrical wires.
BrettF Posted March 11, 2009 Posted March 11, 2009 Good for you, go glow somewhere near the helpfile... Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
myxomatosii Posted March 11, 2009 Author Posted March 11, 2009 (edited) So what is the difference between workingdir and dir where file is located? I looked at the helpfile and I still understand it the same as I did before.. tried @programfilesdir @desktopdir @windowsdir and lots of others, none launched it.. in the example they just run notepad, thats not very helpful considering its an exceptional program that runs out of a directory that regular programs do not it doesn't really help someone understand how to run anything except windows built-in apps.. Edited March 11, 2009 by myxomatosii
BrettF Posted March 11, 2009 Posted March 11, 2009 Please do what I suggested already, SEARCH. I feel quite sure this has been answered many, many times. Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
CodyBarrett Posted March 11, 2009 Posted March 11, 2009 are you sure that is the name of the .exe?.... then KNOW the exact directory path, or put the script into the same folder as it and use @Scriptdir..... @workingdir is just where the script is looking. default is @scriptdir [size="1"][font="Tahoma"][COMPLETED]-----[FAILED]-----[ONGOING]VolumeControl|Binary Converter|CPU Usage| Mouse Wrap |WinHide|Word Scrammbler|LOCKER|SCREEN FREEZE|Decisions Decisions|Version UDF|Recast Desktop Mask|TCP Multiclient EXAMPLE|BTCP|LANCR|UDP serverless|AIOCR|OECR|Recast Messenger|AU3C|Tik-Tak-Toe|Snakes & Ladders|BattleShips|TRON|SNAKE_____________________[u]I love the Helpfile it is my best friend.[/u][/font][/size]
BrettF Posted March 11, 2009 Posted March 11, 2009 Okay, fail search. Lets look at the syntax. Run ( "filename" [, "workingdir" [, show_flag[, opt_flag ]]] ) Workingdir is not used to tell AutoIt where the exe is located; rather it is used to specify where the exe is working. Google it You should put the full path in "filename", yes it is missleading, but put the full path to the exe here. And now here is an example for running a random program, where we set the working dir to the same as the exe. Run ("C:\Path\Goes\Here\This.exe", "C:\Path\Goes\Here") Cheers, Brett Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
evilertoaster Posted March 11, 2009 Posted March 11, 2009 hen I can just type "firefox.exe" into windows and it does it fineYou're probably wanting the more precise functionality of the _RunDOS() function then.
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