Skip to content

Commit

Permalink
Fix the example of Format-Table -DisplayError (#1848)
Browse files Browse the repository at this point in the history
The example is a `-DisplayError` parameter example. But it uses `-ShowError` parameter.
  • Loading branch information
matt9ucci authored and Sean Wheeler committed Nov 9, 2017
1 parent c2abb44 commit 2bdb9e6
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 17 deletions.
11 changes: 7 additions & 4 deletions reference/3.0/Microsoft.PowerShell.Utility/Format-Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
11 changes: 7 additions & 4 deletions reference/4.0/Microsoft.PowerShell.Utility/Format-Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
9 changes: 6 additions & 3 deletions reference/5.0/Microsoft.PowerShell.Utility/Format-Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
9 changes: 6 additions & 3 deletions reference/5.1/Microsoft.PowerShell.Utility/Format-Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
9 changes: 6 additions & 3 deletions reference/6/Microsoft.PowerShell.Utility/Format-Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 2bdb9e6

Please sign in to comment.