Get a reference to the current console host object.
Syntax
Get-Host [CommonParameters]
Key
CommonParameters:
-Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutVariable.
Examples
Display Powershell version and regional information:
PS C:\>get-host
Resize the PowerShell window to 50 pixels high by 80 pixels wide:
PS C:\>$h = get-host
$win = $h.ui.rawui.windowsize
$win.height = 50
$win.width = 80
$h.ui.rawui.set_windowsize($win)
#Though it's cold and lonely in the deep dark night, I can see paradise by the dashboard light# - Meatloaf
Related Powershell Commands:
Read-Host - Read a line of input from the host console
Clear-Host - Clear screen (cls)
Out-Host - Send the pipelined output to the host
Write-Host - Display objects through the user feedback mechanism