Jump to content

Running programs:” The system cannot find the file specified.”


Recommended Posts

What is the command for Run?!?

This works:

Run("notepad.exe")

Also this, after moving a notpad to different location:

Run("notepad.exe",”e:”)

And..

Run("notepad.exe",” e:\su\se”)

Also this works?!?

Run("matlab.exe","D:\MatlabR13\bin\win32")

BUT for example:

Run("maplew9.exe","D:\Maple9\bin.win")

The system cannot find the file specified.

Run("Photoshop.exe","D:\AdobePhotshop7")

The system cannot find the file specified.

Run("WINWORD.EXE","D:\Office2000\OFFICE11")

The system cannot find the file specified.

Also if renaming Winword.exe to a.exe and moving it to some otherplace same error:

Run("a.exe","c:")

The system cannot find the file specified.

Uh?

EDIT: Send("#r") will open them, but should Run("") work also?

Edited by BraveSlice
Link to comment
Share on other sites

From the help file:

WorkingDir is NOT the same as the path to the executable! For example, running a file from a floppy disk:

Bad: Run("myProg.exe", "A:") ; Wrong! This will most likely fail!

Good: Run("A:\myProg.exe") ; Correct because FULL path to executable was given

notepad works because of your PATH settings

a.exe does not work because c: is not in your PATH.

Edited by herewasplato

[size="1"][font="Arial"].[u].[/u][/font][/size]

Link to comment
Share on other sites

From the help file:notepad works because of your PATH settings

a.exe does not work because c: is not in your PATH.

Thx, I didn’t know working dir is not a path.

(Little excuse here, I did not find above mentioned in my Help file, even after I used the information provided here)

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...