Jump to content

Runasset


Recommended Posts

I'm pretty sure the answer is right under my nose, but I just can't see it.

$DomainUserName = "MyNetwork\TheBoss"

$UserPassword = "1234567890"

RunAsSet("DomainUserName", @computername, "UserPassword")

RunWait(..........)

The RunWait line fails, telling me that username and/or password is bad. I'm looking for a way to use my Domain Group credentials in lieu of the remote computer's local admin account to run programs. Is this forbidden? Can I not use the "\" in the detail?

Any Ideas Welcome.

Link to comment
Share on other sites

Yes, you are correct...It is late for me and not at work right now. I'm wondering if the"\" in the construct is being implemented as a math divide command. I don't have a Win2K - XP setup at home to work through this. I was hoping to hit some folks who have found the solution.

RunAsSet($DomainUserName, @computername, $UserPassword)

Link to comment
Share on other sites

  • Developers

Think you also need to split up the domain and username like:

$DomainUserName = "TheBoss"

$DomainName = "MyNetwork"

$UserPassword = "1234567890"

RunAsSet($DomainUserName, $DomainName, $UserPassword)

Edited by JdeB

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Looking with a fresh mind I discovered that the RunAsSet() options are specific.

RunAsSet($AccountName, $AuthenticateWith, $Password)

$AuthenticateWith can be a local account or a network account. A network account can be a member of the network administrator group.

Using a network group administrator account it in this manner, At user loggon the script runs. But only during the loggon and cannot be ran manually.

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