Application Command in Pipeline in Windows PowerShell

Q

Can I use application commands in cmdlet pipeline in Windows PowerShell?

✍: FYIcenter.com

A

Yes, you can use application commands in cmdlet pipeline in Windows PowerShell. But you need to remember a couple of things:

1. The output of an application command will be considered as a String object, not a sequence of characters. For example:

PS C:\fyicenter> ping localhost | get-member -membertype property

   TypeName: System.String

Name   MemberType Definition
----   ---------- ----------
Length Property   int Length {get;}

2. If an output object is piped into an application command, the object will be converted into a sequence of characters before feeding to the application.

 

Introduction of Windows PowerShell Cmdlet

⇒⇒Windows PowerShell Tutorials

2016-11-04, 273👍, 0💬