Tag Archives: function

Product Type Function

This is a small function that will help you with scripts when you need to know if you are on a Workstation or not. The script can also be downloaded in the Download section. http://poweradmin.se/blog/download/?did=2 # Product Type Function # … Continue reading

Posted in PowerShell Blogs | Tagged , , | Leave a comment

Ping-Status function

I use this function when I’m writing scripts that will take information from Servers and Clients when they are on the network. function Ping-Status { ######################################################################## # Ping-Status function # Created: 2009-07-21 # By: Fredrik Wall, fredrik[dot]wall[at]riverpoint[dot]se ######################################################################## param ($mysrv) … Continue reading

Posted in PowerShell Blogs | Tagged , , , | Leave a comment

Get-OSVersion

This is my Get-OSVersion function.   function Get-OSVersion { ######################################################################## # Function: Get Operating System Version # Version: 1.0 # Updated: 2009-07-28 # Code By: Fredrik "Dalle" Wall, Riverpoint AB (fredrik[dot]wall[at]riverpoint[dot]se) ######################################################################## $osver = Get-WmiObject win32_operatingsystem $osver = $osver.version.substring(0,3) switch … Continue reading

Posted in PowerShell Blogs | Tagged , , | Leave a comment