Re: use different Roaming Profiles depending on OS
- From: Björn Urbanek <BjoernUrbanek@xxxxxx>
- Date: Mon, 30 Apr 2007 15:44:31 +0200
Paul Bergson [MVP-DS] schrieb:
A quick run of Scriptomatic and cleanup can help you do this as seen below. This is a WMI Class
On Error Resume Next
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from Win32_OperatingSystem",,48)
For Each objItem in colItems
Wscript.Echo "Caption: " & objItem.Caption
Next
From the script repository on TechNet, a vbscript
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colOSes = objWMIService.ExecQuery("Select * from Win32_OperatingSystem")
For Each objOS in colOSes
Wscript.Echo "Computer Name: " & objOS.CSName
Wscript.Echo "Caption: " & objOS.Caption 'Name
Wscript.Echo "Version: " & objOS.Version 'Version & build
Wscript.Echo "Build Number: " & objOS.BuildNumber 'Build
Wscript.Echo "Build Type: " & objOS.BuildType
Wscript.Echo "OS Type: " & objOS.OSType
Wscript.Echo "Other Type Description: " & objOS.OtherTypeDescription
WScript.Echo "Service Pack: " & objOS.ServicePackMajorVersion & "." & _
objOS.ServicePackMinorVersion
Next
Hello!
Thanks for this answer, but how can I use it to configure an user profile? I have only the opportunity to leave the profil ptah blank or set an profile path.
Thanks a lot!!
*Björn*
.
- Follow-Ups:
- Re: use different Roaming Profiles depending on OS
- From: Paul Bergson [MVP-DS]
- Re: use different Roaming Profiles depending on OS
- References:
- use different Roaming Profiles depending on OS
- From: Björn Urbanek
- Re: use different Roaming Profiles depending on OS
- From: Paul Bergson [MVP-DS]
- use different Roaming Profiles depending on OS
- Prev by Date: Re: DCDiag issues
- Next by Date: Re: SFU intall on domain with 2 controllers
- Previous by thread: Re: use different Roaming Profiles depending on OS
- Next by thread: Re: use different Roaming Profiles depending on OS
- Index(es):
Relevant Pages
|
Loading