Jump to content

Problem with "run"


Recommended Posts

Okay i know this is like such a simple command but for some reason something isnt working out

Run("1.exe", @SystemDir & "\Hello" , @SW_MAXIMIZE)

All it's supposed to do is run the file 1.exe @ c:\Windows\system32\hello\1.exe. (The directory exists).

It always tells me it cant find the specified file (The file also exists).

What's up?

Edited by phatzilla
Link to comment
Share on other sites

Okay i know this is like such a simple command but for some reason something isnt working out

Run("1.exe", @SystemDir & "\Hello" , @SW_MAXIMIZE)

All it's supposed to do is run the file 1.exe @ c:\Windows\system32\hello\1.exe. (The directory exists).

It always tells me it cant find the specified file (The file also exists).

What's up?

Run The Following and you'll see the error of your ways!

MsgBox(0,"Cursor Position:",@SystemDir & "\Hello")

Link to comment
Share on other sites

Is the file located at \windows\system32? Might want to try:

Run(@SystemDir & "\Hello\1.exe", @SystemDir, @SW_MAXIMIZE)
Thank you that fixed it. But why is the 'filename' refered to as "@SystemDir & "\Hello\1.exe"".

I thought the filename is just that, the name of the file which is 1.exe, i didnt know i had to stick the extra directory in there.

Thanks though.

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...