Jump to content

Recommended Posts

Posted (edited)

Hi guys,

I have this batch file that run the following code and it work fine.

C:\Windows\System32\cmd.exe /C set __COMPAT_LAYER=RunAsInvoker & start "" "C:\Program Files\test 123\test 123.exe"

but I'm trying to use autoit @comspec to compile it to a executable file. I'm having problem with the syntax. Can anyone be kind enough to guide me. This is the @comspec code I try.

RunWait(@Comspec & ' /c set __COMPAT_LAYER=RunAsInvoker ' & 'start' & 'C:\Program Files\test 123\test 123.exe')
Edited by lolipop
Posted (edited)

RunWait(@Comspec & ' /c set __COMPAT_LAYER=RunAsInvoker ' & 'start' & 'C:Program Filestest 123test 123.exe')

Should be

RunWait(@Comspec & ' /C set __COMPAT_LAYER=RunAsInvoker & start "" "C:Program Filestest 123test 123.exe"')

Edited by santaryan

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
×
×
  • Create New...