Sign in to follow this  
Followers 0
BraveSlice

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

4 posts in this topic

#1 ·  Posted (edited)

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

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

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]

Share this post


Link to post
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)

Share this post


Link to post
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
Sign in to follow this  
Followers 0