Jump to content

Use Directory Macro in Run Command


Recommended Posts

Hi,

I am brand new to scripting and AutoIT. I am attempting to use @SystemDir in a run command and chain a filename (& possibly a folder) to it.

The line I'm trying to use is:

Run("mmc","C:\Build",/o," " & @SystemDir & "\" & services.msc)

The result is:

C:\Build\MyScript.au3 (13) : ==> Error parsing function call.:

Run("mmc","C:\Build",/o," " & @SystemDir & "\" & services.msc)

Run("mmc","C:\Build",/^ ERROR

>Exit code: 0

Can I use this command to launch Mmc.exe? What is the proper syntax to chain a Directory Macro with a folder & filename? Is there a better way to do this?

Any help is appreciated.

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