Guest wisemto Posted July 13, 2004 Share Posted July 13, 2004 In the RunOnceEx of the registry I have placed a script that was compiled into ViewStar.exe and contains the following code: ; Set the RunAs parameters to use domain admin account RunAsSet("softinst", "DOMAINNAME", "PASSWORD") ; Run registry editor as admin RunWait("\\antioch\bpm\rr01\Install\vssetup\setup.exe /s") RunWait("\\oxfnas1\viewstar\icon.bat") ; Reset user's permissions RunAsSet() We have our workstations locked down.. I thought with the run as above it would run as the domain admin account. It does run from the directory but will not update the registry. If I log onto the locked machine it runs as a domain admin and the software installs fine. Any Help would be appreciated.. Thanks Link to comment Share on other sites More sharing options...
Doxie Posted July 13, 2004 Share Posted July 13, 2004 I just had the same problem and solved it by using NET USE. The code below could work for you. Run("net use z: \\antioch\bpm\rr01\Install\vssetup\ /user:username password /y") While DriveStatus("z:\") <> "READY";Checking if Z is ready Sleep(100) WEnd RunWait("z:\setup.exe /s");Running the file Run("net use z: /d");Deleting Z Sleep(5000);Wait 5 seconds Run("net use x: \\oxfnas1\viewstar\ /user:username password /y") While DriveStatus("x:\") <> "READY";Checking if X is ready Sleep(100) WEnd RunWait("x:\icon.bat /s");Running the file Run("net use x: /d");Deleting X Sleep(5000) Their might be better ways, but this worked for me. Were ever i lay my script is my home... Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now