Skip to content

Commit 4ac1524

Browse files
sdwheelerDCtheGeek
authored andcommitted
Fix #3963 - note Paging is not supported by ISE (#4055)
* Fix #3963 - note Paging is not supported by ISE * attempt to fix build error * fix build error
1 parent b9938d5 commit 4ac1524

File tree

6 files changed

+256
-137
lines changed

6 files changed

+256
-137
lines changed

reference/3.0/Microsoft.PowerShell.Core/Out-Host.md

Lines changed: 46 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
ms.date: 06/09/2017
2+
ms.date: 03/25/2019
33
schema: 2.0.0
44
locale: en-us
55
keywords: powershell,cmdlet
@@ -10,7 +10,6 @@ title: Out-Host
1010
# Out-Host
1111

1212
## SYNOPSIS
13-
1413
Sends output to the command line.
1514

1615
## SYNTAX
@@ -21,39 +20,41 @@ Out-Host [-Paging] [-InputObject <PSObject>] [<CommonParameters>]
2120

2221
## DESCRIPTION
2322

24-
The **Out-Host** cmdlet sends output to the Windows PowerShell host for display.
25-
The host displays the output at the command line.
26-
Because **Out-Host** is the default, you do not need to specify it unless you want to use its parameters to change the display.
23+
The `Out-Host` cmdlet sends output to the PowerShell host for display. The host displays the output
24+
at the command line. Because `Out-Host` is the default, you do not have to specify it unless you
25+
want to use its parameters to change the display.
2726

2827
## EXAMPLES
2928

30-
### Example 1
29+
### Example 1: Display system processes one page at a time
30+
3131
```powershell
3232
Get-Process | Out-Host -Paging
3333
```
3434

35-
This command displays the processes on the system one page at a time.
36-
It uses the `Get-Process` cmdlet to get the processes on the system.
37-
The pipeline operator sends the results to `Out-Host` cmdlet, which displays them at the console.
38-
The **Paging** parameter displays one page of data at a time.
35+
This command displays the processes on the system one page at a time. It uses the `Get-Process`
36+
cmdlet to get the processes on the system. The pipeline operator sends the results to `Out-Host`
37+
cmdlet, which displays them at the console. The **Paging** parameter displays one page of data at a
38+
time.
3939

40-
### Example 2
40+
### Example 2: Display session history
4141

42-
```
43-
PS> $a = Get-History
44-
PS> Out-Host -InputObject $a
42+
```powershell
43+
$a = Get-History
44+
Out-Host -InputObject $a
4545
```
4646

47-
These commands display the session history at the command line.
48-
The first command uses the Get-History cmdlet to get the session history, and then it stores the history in the $a variable.
49-
The second command uses **Out-Host** to display the content of the $a variable, and it uses the **InputObject** parameter to specify the variable to **Out-Host**.
47+
The first command uses the `Get-History` cmdlet to get the session history, and then it stores the
48+
history in the `$a` variable.
49+
50+
The second command uses `Out-Host` to display the content of the `$a` variable, and it uses the **InputObject** parameter to specify the variable to `Out-Host`.
5051

5152
## PARAMETERS
5253

5354
### -InputObject
5455

55-
Specifies the objects that are written to the console.
56-
Enter a variable that contains the objects, or type a command or expression that gets the objects.
56+
Specifies the objects that are written to the console. Enter a variable that contains the objects,
57+
or type a command or expression that gets the objects.
5758

5859
```yaml
5960
Type: PSObject
@@ -69,9 +70,13 @@ Accept wildcard characters: False
6970
7071
### -Paging
7172
72-
Displays one page of output at a time, and waits for user input before displaying the remaining pages, much like the traditional "more" command.
73-
By default, all of the output is displayed on a single page.
74-
The page size is determined by the characteristics of the host.
73+
Indicates that this cmdlet displays one page of output at a time, and waits for user input before it
74+
displays the remaining pages, much like the traditional **more** command. By default, all of the
75+
output is displayed on a single page. The page size is determined by the characteristics of the
76+
host.
77+
78+
> [!NOTE]
79+
> The **Paging** parameter is not supported by the PowerShell ISE host.
7580
7681
```yaml
7782
Type: SwitchParameter
@@ -87,28 +92,39 @@ Accept wildcard characters: False
8792
8893
### CommonParameters
8994
90-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](./About/about_CommonParameters.md).
95+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
96+
-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose,
97+
-WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
9198
9299
## INPUTS
93100
94101
### System.Management.Automation.PSObject
95102
96-
You can pipe any object to **Out-Host**.
103+
You can pipe any object to this cmdlet.
97104
98105
## OUTPUTS
99106
100107
### None
101108
102-
**Out-Host** does not generate any output.
103-
However, the host might display the objects that **Out-Host** sends to it.
109+
This cmdlet does not generate any output. However, the host might display the objects that
110+
`Out-Host` sends to it.
104111

105112
## NOTES
106113

107-
- The cmdlets that contain the Out verb (the Out cmdlets) do not format objects; they just render them and send them to the specified display destination. If you send an unformatted object to an Out cmdlet, the cmdlet sends it to a formatting cmdlet before rendering it.
108-
- The Out cmdlets do not have parameters for names or file paths. To send data to an Out cmdlet, use a pipeline operator (|) to send the output of a Windows PowerShell command to the cmdlet. You can also store data in a variable and use the InputObject parameter to pass the data to the cmdlet. For help, see the examples.
109-
- **Out-Host** sends data, but it does not emit any output objects. If you pipe the output of **Out-Host** to the Get-Member cmdlet, **Get-Member** reports that no objects have been specified.
114+
The **Paging** parameter is not supported by all PowerShell hosts. For example, when you try to
115+
use the **Paging** parameter in the PowerShell ISE, you see the following error: `out-lineoutput : The method or operation is not implemented.`
116+
117+
The cmdlets that contain the **Out** verb (the `Out-*` cmdlets) do not format objects. They just
118+
render objects and send them to the specified display destination. If you send an unformatted object
119+
to an `Out-*` cmdlet, the cmdlet sends it to a formatting cmdlet before rendering it.
120+
121+
The `Out-*` cmdlets do not have parameters for names or file paths. To send data to an `Out-*`
122+
cmdlet, use a pipeline operator (|) to send the output of a PowerShell command to the cmdlet. You
123+
can also store data in a variable and use the **InputObject** parameter to pass the data to the
124+
cmdlet.
110125

111-
-
126+
`Out-Host` sends data, but it does not emit any output objects. If you pipe the output of `Out-Host`
127+
to the `Get-Member` cmdlet, `Get-Member` reports that no objects have been specified.
112128

113129
## RELATED LINKS
114130

reference/4.0/Microsoft.PowerShell.Core/Out-Host.md

Lines changed: 54 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
---
2-
ms.date: 06/09/2017
2+
ms.date: 03/25/2019
33
schema: 2.0.0
44
locale: en-us
55
keywords: powershell,cmdlet
66
online version: http://go.microsoft.com/fwlink/p/?linkid=289601
77
external help file: System.Management.Automation.dll-Help.xml
88
title: Out-Host
99
---
10-
1110
# Out-Host
1211

1312
## SYNOPSIS
@@ -20,37 +19,42 @@ Out-Host [-Paging] [-InputObject <PSObject>] [<CommonParameters>]
2019
```
2120

2221
## DESCRIPTION
23-
The **Out-Host** cmdlet sends output to the Windows PowerShell host for display.
24-
The host displays the output at the command line.
25-
Because **Out-Host** is the default, you do not need to specify it unless you want to use its parameters to change the display.
22+
23+
The `Out-Host` cmdlet sends output to the PowerShell host for display. The host displays the output
24+
at the command line. Because `Out-Host` is the default, you do not have to specify it unless you
25+
want to use its parameters to change the display.
2626

2727
## EXAMPLES
2828

29-
### Example 1
29+
### Example 1: Display system processes one page at a time
30+
3031
```powershell
3132
Get-Process | Out-Host -Paging
3233
```
3334

34-
This command displays the processes on the system one page at a time.
35-
It uses the `Get-Process` cmdlet to get the processes on the system.
36-
The pipeline operator sends the results to `Out-Host` cmdlet, which displays them at the console.
37-
The **Paging** parameter displays one page of data at a time.
35+
This command displays the processes on the system one page at a time. It uses the `Get-Process`
36+
cmdlet to get the processes on the system. The pipeline operator sends the results to `Out-Host`
37+
cmdlet, which displays them at the console. The **Paging** parameter displays one page of data at a
38+
time.
3839

39-
### Example 2
40-
```
41-
PS C:\> $a = Get-History
42-
PS C:\> Out-Host -InputObject $a
40+
### Example 2: Display session history
41+
42+
```powershell
43+
$a = Get-History
44+
Out-Host -InputObject $a
4345
```
4446

45-
These commands display the session history at the command line.
46-
The first command uses the Get-History cmdlet to get the session history, and then it stores the history in the $a variable.
47-
The second command uses **Out-Host** to display the content of the $a variable, and it uses the **InputObject** parameter to specify the variable to **Out-Host**.
47+
The first command uses the `Get-History` cmdlet to get the session history, and then it stores the
48+
history in the `$a` variable.
49+
50+
The second command uses `Out-Host` to display the content of the `$a` variable, and it uses the **InputObject** parameter to specify the variable to `Out-Host`.
4851

4952
## PARAMETERS
5053

5154
### -InputObject
52-
Specifies the objects that are written to the console.
53-
Enter a variable that contains the objects, or type a command or expression that gets the objects.
55+
56+
Specifies the objects that are written to the console. Enter a variable that contains the objects,
57+
or type a command or expression that gets the objects.
5458

5559
```yaml
5660
Type: PSObject
@@ -65,9 +69,14 @@ Accept wildcard characters: False
6569
```
6670
6771
### -Paging
68-
Displays one page of output at a time, and waits for user input before displaying the remaining pages, much like the traditional "more" command.
69-
By default, all of the output is displayed on a single page.
70-
The page size is determined by the characteristics of the host.
72+
73+
Indicates that this cmdlet displays one page of output at a time, and waits for user input before it
74+
displays the remaining pages, much like the traditional **more** command. By default, all of the
75+
output is displayed on a single page. The page size is determined by the characteristics of the
76+
host.
77+
78+
> [!NOTE]
79+
> The **Paging** parameter is not supported by the PowerShell ISE host.
7180
7281
```yaml
7382
Type: SwitchParameter
@@ -82,25 +91,40 @@ Accept wildcard characters: False
8291
```
8392
8493
### CommonParameters
85-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
94+
95+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
96+
-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose,
97+
-WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
8698
8799
## INPUTS
88100
89101
### System.Management.Automation.PSObject
90-
You can pipe any object to **Out-Host**.
102+
103+
You can pipe any object to this cmdlet.
91104
92105
## OUTPUTS
93106
94107
### None
95-
**Out-Host** does not generate any output.
96-
However, the host might display the objects that **Out-Host** sends to it.
108+
109+
This cmdlet does not generate any output. However, the host might display the objects that
110+
`Out-Host` sends to it.
97111

98112
## NOTES
99-
* The cmdlets that contain the Out verb (the Out cmdlets) do not format objects; they just render them and send them to the specified display destination. If you send an unformatted object to an Out cmdlet, the cmdlet sends it to a formatting cmdlet before rendering it.
100-
* The Out cmdlets do not have parameters for names or file paths. To send data to an Out cmdlet, use a pipeline operator (|) to send the output of a Windows PowerShell command to the cmdlet. You can also store data in a variable and use the InputObject parameter to pass the data to the cmdlet. For help, see the examples.
101-
* **Out-Host** sends data, but it does not emit any output objects. If you pipe the output of **Out-Host** to the Get-Member cmdlet, **Get-Member** reports that no objects have been specified.
102113

103-
*
114+
The **Paging** parameter is not supported by all PowerShell hosts. For example, when you try to
115+
use the **Paging** parameter in the PowerShell ISE, you see the following error: `out-lineoutput : The method or operation is not implemented.`
116+
117+
The cmdlets that contain the **Out** verb (the `Out-*` cmdlets) do not format objects. They just
118+
render objects and send them to the specified display destination. If you send an unformatted object
119+
to an `Out-*` cmdlet, the cmdlet sends it to a formatting cmdlet before rendering it.
120+
121+
The `Out-*` cmdlets do not have parameters for names or file paths. To send data to an `Out-*`
122+
cmdlet, use a pipeline operator (|) to send the output of a PowerShell command to the cmdlet. You
123+
can also store data in a variable and use the **InputObject** parameter to pass the data to the
124+
cmdlet.
125+
126+
`Out-Host` sends data, but it does not emit any output objects. If you pipe the output of `Out-Host`
127+
to the `Get-Member` cmdlet, `Get-Member` reports that no objects have been specified.
104128

105129
## RELATED LINKS
106130

0 commit comments

Comments
 (0)