From 8e9b090a4556f51067c2e00272bd4088caeba556 Mon Sep 17 00:00:00 2001 From: Matt Gucci <matt9ucci@gmail.com> Date: Thu, 9 Nov 2017 23:18:23 +0900 Subject: [PATCH] Fix the example of `Format-Table -DisplayError` The example is a `-DisplayError` parameter example. But it uses `-ShowError` parameter. --- .../3.0/Microsoft.PowerShell.Utility/Format-Table.md | 11 +++++++---- .../4.0/Microsoft.PowerShell.Utility/Format-Table.md | 11 +++++++---- .../5.0/Microsoft.PowerShell.Utility/Format-Table.md | 9 ++++++--- .../5.1/Microsoft.PowerShell.Utility/Format-Table.md | 9 ++++++--- .../6/Microsoft.PowerShell.Utility/Format-Table.md | 9 ++++++--- 5 files changed, 32 insertions(+), 17 deletions(-) diff --git a/reference/3.0/Microsoft.PowerShell.Utility/Format-Table.md b/reference/3.0/Microsoft.PowerShell.Utility/Format-Table.md index c9542ce4b85f..7bdc4cfc66ef 100644 --- a/reference/3.0/Microsoft.PowerShell.Utility/Format-Table.md +++ b/reference/3.0/Microsoft.PowerShell.Utility/Format-Table.md @@ -132,14 +132,17 @@ Accept wildcard characters: False ``` ### -DisplayError -Displays errors at the command line. -This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a Format-Table command, and the expressions do not appear to be working. -The following shows an example of the results of adding the DisplayError parameter with an expression. +Indicates that the cmdlet displays errors at the command line. +This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a `Format-Table` command, and the expressions do not appear to be working. +The following shows an example of the results of adding the **DisplayError** parameter with an expression. + +```powershell +PS C:\> Get-Date | Format-Table DayOfWeek, { $_ / $null } -DisplayError -PS \> Get-Date | Format-Table DayOfWeek,{ $_ / $null } -ShowError DayOfWeek $_ / $null --------- ------------ Wednesday #ERR +``` ```yaml Type: SwitchParameter diff --git a/reference/4.0/Microsoft.PowerShell.Utility/Format-Table.md b/reference/4.0/Microsoft.PowerShell.Utility/Format-Table.md index 1c0b53dafa5b..e8d22e7cd77a 100644 --- a/reference/4.0/Microsoft.PowerShell.Utility/Format-Table.md +++ b/reference/4.0/Microsoft.PowerShell.Utility/Format-Table.md @@ -141,14 +141,17 @@ Accept wildcard characters: False ``` ### -DisplayError -Displays errors at the command line. -This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a Format-Table command, and the expressions do not appear to be working. -The following shows an example of the results of adding the DisplayError parameter with an expression. +Indicates that the cmdlet displays errors at the command line. +This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a `Format-Table` command, and the expressions do not appear to be working. +The following shows an example of the results of adding the **DisplayError** parameter with an expression. + +```powershell +PS C:\> Get-Date | Format-Table DayOfWeek, { $_ / $null } -DisplayError -PS \> Get-Date | Format-Table DayOfWeek,{ $_ / $null } -ShowError DayOfWeek $_ / $null --------- ------------ Wednesday #ERR +``` ```yaml Type: SwitchParameter diff --git a/reference/5.0/Microsoft.PowerShell.Utility/Format-Table.md b/reference/5.0/Microsoft.PowerShell.Utility/Format-Table.md index 539afbcb6d08..1965eb28091c 100644 --- a/reference/5.0/Microsoft.PowerShell.Utility/Format-Table.md +++ b/reference/5.0/Microsoft.PowerShell.Utility/Format-Table.md @@ -142,13 +142,16 @@ Accept wildcard characters: False ### -DisplayError Indicates that the cmdlet displays errors at the command line. -This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a **Format-Table** command, and the expressions do not appear to be working. -The following shows an example of the results of adding the DisplayError parameter with an expression. +This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a `Format-Table` command, and the expressions do not appear to be working. +The following shows an example of the results of adding the **DisplayError** parameter with an expression. + +```powershell +PS C:\> Get-Date | Format-Table DayOfWeek, { $_ / $null } -DisplayError -PS \> Get-Date | Format-Table DayOfWeek,{ $_ / $null } -ShowError DayOfWeek $_ / $null --------- ------------ Wednesday #ERR +``` ```yaml Type: SwitchParameter diff --git a/reference/5.1/Microsoft.PowerShell.Utility/Format-Table.md b/reference/5.1/Microsoft.PowerShell.Utility/Format-Table.md index 9f9cd1d532db..fad250d7ec9e 100644 --- a/reference/5.1/Microsoft.PowerShell.Utility/Format-Table.md +++ b/reference/5.1/Microsoft.PowerShell.Utility/Format-Table.md @@ -142,13 +142,16 @@ Accept wildcard characters: False ### -DisplayError Indicates that the cmdlet displays errors at the command line. -This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a **Format-Table** command, and the expressions do not appear to be working. -The following shows an example of the results of adding the DisplayError parameter with an expression. +This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a `Format-Table` command, and the expressions do not appear to be working. +The following shows an example of the results of adding the **DisplayError** parameter with an expression. + +```powershell +PS C:\> Get-Date | Format-Table DayOfWeek, { $_ / $null } -DisplayError -PS \> Get-Date | Format-Table DayOfWeek,{ $_ / $null } -ShowError DayOfWeek $_ / $null --------- ------------ Wednesday #ERR +``` ```yaml Type: SwitchParameter diff --git a/reference/6/Microsoft.PowerShell.Utility/Format-Table.md b/reference/6/Microsoft.PowerShell.Utility/Format-Table.md index c49e5a3c9694..cd46af1d30c1 100644 --- a/reference/6/Microsoft.PowerShell.Utility/Format-Table.md +++ b/reference/6/Microsoft.PowerShell.Utility/Format-Table.md @@ -142,13 +142,16 @@ Accept wildcard characters: False ### -DisplayError Indicates that the cmdlet displays errors at the command line. -This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a **Format-Table** command, and the expressions do not appear to be working. -The following shows an example of the results of adding the DisplayError parameter with an expression. +This parameter is rarely used, but can be used as a debugging aid when you are formatting expressions in a `Format-Table` command, and the expressions do not appear to be working. +The following shows an example of the results of adding the **DisplayError** parameter with an expression. + +```powershell +PS C:\> Get-Date | Format-Table DayOfWeek, { $_ / $null } -DisplayError -PS \> Get-Date | Format-Table DayOfWeek,{ $_ / $null } -ShowError DayOfWeek $_ / $null --------- ------------ Wednesday #ERR +``` ```yaml Type: SwitchParameter