PSItem
suggest changeGet-Process | ForEach-Object -Process {
$PSItem.Name
}
Same as $_. $PSItem contains the current object in the pipeline. The $PSItem name was added in Windows PowerShell 3.0. You can use this variable in commands that perform an action on every object, or on selected objects, in a pipeline.
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents