Jump to content
Sign in to follow this  
timbrigham

RunAsSet replacement?

Recommended Posts

timbrigham

I've used AutoIT for years. I know that the RunAsSet function has been depreciated and removed but I need the functionality described in pseudo code. I effectively need to run a custom AutoIT function under the alternative user. I do *not* want to run an external executable. I really don't want to break this out into a bunch of separate executables - there are several cases and configurations like this that need to be defined and it would require a whole lot of command line arguments in some cases. Any suggestions would be much appreciated.

$Input=ReadIni( "C:\Users\User1\Test.ini", "Section", "Key", "Value" )
RunAsSet(Alt,Credentials)
If( ReadIni("C:\Users\User2\Test.ini","Section","Key","Value" )
WriteIni("Test.ini","Section","Key","Value", $Input )
Fi
RunAsSet()

Share this post


Link to post
Share on other sites
AdmiralAlkex

Hi and Welcome to the forums!!

RunAsSet() never did anything like that, it was just for running executables. Like RunAs() do now. What you are describing is not possible as is.

I do *not* want to run an external executable. I really don't want to break this out into a bunch of separate executables

So put everything in the same exe and use command lines to set what should happen?

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  

×