Powershell

OBJ 2 – Task5 : Get-Process | Sort Name -Descending | ConvertTo-HTML –Property Name,ID,VM,PM | Out-File c:ProcReport.html

OBJ 3 – Task 2 : New-Item c:ScriptOutput -ItemType directory

OBJ 3 – Task 7 :

$x = 1..5
$x.Count
$x[3,4] or $x[-2,($x.count-1)] or $x[-2,-1]
$y = “red”,”white”,”blue”
$z = $x + $y

OBJ 4 – Task 3: Get-Volume |Where-Object { $PSItem.SizeRemaining -gt 0 -and $PSItem.SizeRemaining / $PSItem.Size -lt .1 }

Get-Volume |Where-Object { $PSItem.SizeRemaining -gt 0 -and $PSItem.SizeRemaining /$PSItem.Size -lt .99 }

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s