Re: Running a logon script under another account

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Thanks, I'll give it a try and let you know how it works out.

I guess this solution depends on the focus being in the password textbox.

"JHP" <goawayspam@xxxxxxx> wrote in message
news:O$Pp%2332yFHA.2792@xxxxxxxxxxxxxxxxxxxxxxx
> Not sure if this will work for you, but it's worth a try:
>
> Option Explicit
>
> Dim objShell
> Const WindowStyle = 2
> Const WaitOnReturn = False
>
> Set objShell = Wscript.CreateObject("WScript.Shell")
> objShell.Run "RunAs /user:ACCOUNT@DOMAIN " &_
> "C:\DIRECTORY\VSSetup.exe""", WindowStyle, WaitOnReturn
> WScript.Sleep 100
> objShell.Sendkeys "PASSWORD~"
> Set objShell = Nothing
>
> "Peter Avalos" <petera@xxxxxxxxxxx> wrote in message
> news:e6hWTT1yFHA.1856@xxxxxxxxxxxxxxxxxxxxxxx
>> Does anyone know how to run a .vbs logon script under a different account
>> than the account that's logging in? The reason I need to do this is that
>> the script installs a software package if it's not already installed on
>> the machine that the user is logging onto. The Active Directory Group
>> Policy restricts software installation to domain administrators, so I
>> wanted to run this script with elevated priviledges to get around this
>> restriction imposed by the Group Policy. Has anyone effectively dealt
>> with a similar issue?
>>
>> Some background info:
>> --All client machines are Windows XP Pro
>> --Main AD Server (Global Catalog) is 2003. Other domain controllers are
>> 2003 and 2000
>>
>>
>
>


.



Relevant Pages

  • Re: Switch between AccessXP and Access2003
    ... kills the shell, creates an instance of Access, sets its automationsecurity ... The script successfully installs 2003, ... Repair on 2003 and keep it installed, then my script will work because it is ... Dim PathToMDE ...
    (microsoft.public.access.security)
  • Re: Switch between AccessXP and Access2003
    ... The script successfully installs 2003, ... error indicating automationsecurity is not supported. ... Repair on 2003 and keep it installed, then my script will work because it ... Dim PathToMDE ...
    (microsoft.public.access.security)
  • Switch between AccessXP and Access2003
    ... kills the shell, creates an instance of Access, sets its automationsecurity ... The script successfully installs 2003, ... Repair on 2003 and keep it installed, then my script will work because it is ... Dim PathToMDE ...
    (microsoft.public.access.security)
  • Re: Quarantine Control Script
    ... "Quarantine Control" ... If I take out above phrase, which any keyword automation ... The earliest script that would execute is likely autoexec.bat. ... telling or preventing 'installs' of ...
    (microsoft.public.scripting.wsh)
  • Re: [SLE] Microsoft fonts update
    ... The 'update' is really just a script that downloads the fonts and a required ... utility from sourceforge.net and installs them. ...
    (SuSE)