Werbung: SecurityConsole.de verwaltet Ihre Computer mit Security Essentails aus der Cloud!
30 Tage kostenfrei testen und 20% Rabatt für Ihre Bestellung mit Promocode: WBF2685582
(Promocode gültig bis 31.12.2011)

Group:  English: Windows Server » microsoft.public.windows.server.scripting
Thread: How to run a script by a domain user ?

HTVi
TV Discussion Newsgroups

How to run a script by a domain user ?
"Sunny Chan" <cl_edp[ at ]sina.com> 12/30/2008 2:42:26 PM
Hi,

My question is how to let the domain user run the logon script.

************************************************************************************
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colNetAdapters = objWMIService.ExecQuery _
("Select * From Win32_NetworkAdapterConfiguration Where IPEnabled =
True")
For Each objNetAdapter in colNetAdapters
objNetAdapter.SetGateways array()
next
************************************************************************************

About this logon script, the users of Domain Admin can be run. But the users
of Domain User can not.


Re: How to run a script by a domain user ?
"Pegasus \(MVP\)" <I.can[ at ]fly.com.oz> 12/30/2008 4:17:11 PM

"Sunny Chan" <cl_edp[ at ]sina.com> wrote in message
news:uPiOXzoaJHA.4664[ at ]TK2MSFTNGP06.phx.gbl...
[Quoted Text]
> Hi,
>
> My question is how to let the domain user run the logon script.
>
> ************************************************************************************
> strComputer = "."
> Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
> Set colNetAdapters = objWMIService.ExecQuery _
> ("Select * From Win32_NetworkAdapterConfiguration Where IPEnabled =
> True")
> For Each objNetAdapter in colNetAdapters
> objNetAdapter.SetGateways array()
> next
> ************************************************************************************
>
> About this logon script, the users of Domain Admin can be run. But the
> users of Domain User can not.

See the many replies you received in the scripting.vbscript newsgroup and
have a look here about the merits of cross-posting vs. multi-posting:
http://www.blakjak.demon.co.uk/mul_crss.htm. If you wish to extend the
exposure of your original post then cross-posting is the recommended method
to avoid duplication of effort.


Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net
Suche nach Orten, Städten, Postleitzahlen, Vorwahlen, Kfz-Kennzeichen