Format-Table [[-Property] <Object[]>] [-AutoSize] [-RepeatHeader] [-HideTableHeaders] [-Wrap] [-GroupBy <Object>] [-View <string>] [-ShowError] [-DisplayError] [-Force] [-Expand <string>] [-InputObject <psobject>] [<CommonParameters>]说明...
你还可以通过使用 Wrap 参数让较长的 Format-Table 数据在其显示列中自动换行。 仅使用 Wrap 参数不一定会实现所需的操作,因为如果你不同时指定 AutoSize,它会使用默认设置: PS> Get-Process -Name powershell | Format-Table -Wrap -Property Name,Id,Company,Path Name Id Company Path --- -- --- --...
您可以使用Wrap參數,強制冗長的Format-Table數據在其顯示列中換行。 使用Wrap參數可能無法執行您預期的情況,因為如果您未指定AutoSize,則會使用預設設定: PowerShell Get-Service-Namewin* |Format-Table-PropertyName, Status, StartType, DisplayName, DependentServices-Wrap ...
Format-Table [[-Property] <Object[]>] [-AutoSize] [-RepeatHeader] [-HideTableHeaders] [-Wrap] [-GroupBy <Object>] [-View <string>] [-ShowError] [-DisplayError] [-Force] [-Expand <string>] [-InputObject <psobject>] [<CommonParameters>]Description...
Format-Table[[-Property] <Object[]>] [-AutoSize] [-RepeatHeader] [-HideTableHeaders] [-Wrap] [-GroupBy <Object>] [-View <string>] [-ShowError] [-DisplayError] [-Force] [-Expand <string>] [-InputObject <psobject>] [<CommonParameters>] ...
Formats the output as a table. Syntax PowerShellCopy Format-Table[[-Property] <Object[]>] [-AutoSize] [-RepeatHeader] [-HideTableHeaders] [-Wrap] [-GroupBy <Object>] [-View <string>] [-ShowError] [-DisplayError] [-Force] [-Expand <string>] [-InputObject <psobject>] [<CommonParam...
Format-Table[[-Property] <Object[]>] [-AutoSize] [-RepeatHeader] [-HideTableHeaders] [-Wrap] [-GroupBy <Object>] [-View <string>] [-ShowError] [-DisplayError] [-Force] [-Expand <string>] [-InputObject <psobject>] [<CommonParameters>] ...
{$_.Freespace /1Gb -as [int]}} | Format-Table -AutoSize __SERVER FreeGB --- --- 08DC1 21 其中用于构造显示属性,第一个为__Server,第二个是自定义的FreeGB,用wmiobject对象的Freespace属性除以1/GB并以int类型显示 Select-Object -Property __Server,@{n='FreeGB ';e={$_.Freespace /1Gb...
PS>Get-Alias-Definition Invoke-WebRequest|Format-Table-AutoSize CommandType Name Version Source---Alias curl->Invoke-WebRequest Alias iwr->Invoke-WebRequest Alias wget->Invoke-WebRequest Invoke-WebRequest简单用法 1.用途 Gets content from a web page...
Get-WinEvent-LogName*PowerShell*,Microsoft-Windows-Kernel-WHEA* |Group-Object-PropertyLevelDisplayName, LogName-NoElement|Format-Table-AutoSizeCount Name --- ---1Error, PowerShellCore/Operational26Information,Microsoft-Windows-Kernel-WHEA/Operational488Information,Microsoft-Windows-PowerShell/Operational...