Jump to content
Sign in to follow this  
MerkurAlex

RunAs a bat file

Recommended Posts

MerkurAlex

I have tried everything i can think of i have used

@comspec&" /c test.bat"

and variations but it refuses to work and yes my username and password is all correct it works on normal exe's


[quote name='PsaltyDS' post='635433' date='Jan 27 2009, 07:04 AM']Larry is a mass murderer?! It's always the quiet, clean cut, bald guys... [/quote]

Share this post


Link to post
Share on other sites
Mobius

Run("CMD.exe /C TEST.bat");Close
Run("CMD.exe /K TEST.bat");Remain

This works, changing the workingdir to a valid path didn't.

I did only try it with the @COMSPEC macro though.

You could also just use, Run("TEST.bat")

Edited by Mobius

Share this post


Link to post
Share on other sites
MerkurAlex

Run("CMD.exe /C TEST.bat");Close
Run("CMD.exe /K TEST.bat");Remain

This works, changing the workingdir to a valid path didn't.

I did only try it with the @COMSPEC macro though.

You could also just use, Run("TEST.bat")

yea i know it works with run but runas wont run properly with a batch file.

[quote name='PsaltyDS' post='635433' date='Jan 27 2009, 07:04 AM']Larry is a mass murderer?! It's always the quiet, clean cut, bald guys... [/quote]

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  

×