Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Windows Components

Status
Not open for further replies.

GerhardR

IS-IT--Management
Feb 24, 2005
90
AT
Hi!

Is it possible to add via SMS Windows Components like SNMP and WMI SNMP?

And I also have to add a service for which a lot of properties have to be set - is that also possible?

Thanks for any help!

Gerhard
 
here is a link to a script that does it:


and as far as installing a service goes..a vb script:


Const OWN_PROCESS = 16
Const NOT_INTERACTIVE = False
Const NORMAL_ERROR_CONTROL = 2
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set objService = objWMIService.Get("Win32_BaseService")
errReturn = objService.Create("MyService" ,"My Service" , "c:\windows\system32\mynewservice.exe", OWN_PROCESS, NORMAL_ERROR_CONTROL, "Manual", NOT_INTERACTIVE, "NT AUTHORITY\LocalService", "" )
Wscript.Echo errReturn
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top