UPTIME
$myobj.uptime = (Get-Date) - [System.DateTime]::ParseExact($OSInfo.LastBootUpTime.Split(".")[0],'yyyyMMddHHmmss',$null)
$myobj.uptime = "$($myobj.uptime.Days) days, $($myobj.uptime.Hours) hours," +`
" $($myobj.uptime.Minutes) minutes, $($myobj.uptime.Seconds) seconds"
No comments:
Post a Comment