# This is a example taken from the book "Microsoft Windows Powershell Step by step"
$wmi = get-wmiobject win32_computersystem
"computer " + $wmi.name + " is: "
switch ($wmi.domainrole)
   {
   0 {"`t Stand alone workstation"}
   1 {"`t Member workstation"}
   2 {"`t Stand alone server"}
   3 {"`t Member server"}
   4 {"`t Back up domain controller"}
   5 {"`t Primary domain controller"}
   default {"`t The role can not be determined"}
   }
Subscribe to:
Post Comments (Atom)
- 
All WMI Class Names list : - Name ...
 - 
Functions are loosely typed in javascript, we are able to pass different types of parameters, too few args, too many argos etc. Keep functio...
 - 
Hi All, Thanks for taking out time to read this post. Can someone help me with this? When I try to run this, System.TypeLoadExeception Error...
 
No comments:
Post a Comment