How do we export the information we need to be in the format we want, this section, which focuses on formatting output results
can use format-list commands are displayed in columnar format
Get-mailbox Robin.pang | Format-list
You can also enter a table style for the result
Get-mailbox Robin.pang | Format-table Name,alias
650) this.width=650; "title=" 01.png "style=" Float:none; "src=" http://s3.51cto.com/wyfs02/M01/58/FE/ Wkiol1tdybttejamaacatv6b-_q156.jpg "alt=" Wkiol1tdybttejamaacatv6b-_q156.jpg "/>
I can use it. AutoSize parameter makes the data in the table adaptive width
Get-mailbox San.zhang | Format-table name,alias–autosize
650) this.width=650; "title=" 02.png "style=" Float:none; "src=" http://s3.51cto.com/wyfs02/M01/59/01/ Wkiom1tdxzmt9sfzaab0ocbkqxy098.jpg "alt=" Wkiom1tdxzmt9sfzaab0ocbkqxy098.jpg "/>
In the above command, I can use FL Replace format-list , ft Replace format-table
650) this.width=650; "title=" 03.png "style=" Float:none; "src=" http://s3.51cto.com/wyfs02/M02/58/FE/ Wkiol1tdybsiqzuxaabrimjtvby344.jpg "alt=" Wkiol1tdybsiqzuxaabrimjtvby344.jpg "/>
More commands:
Output structure to text
Get-mailbox Robin.pang | FL * | Out-file C:\test.txt
in the above command, we can also use the command " > " or ">>" Making text Output
Get-mailboxdatabase | Sort name | FT name
Get-mailboxdatabase | Sort Name–desc | FT name
This article from "Robin's Home" blog, declined reprint!
Exchange-PowerShell formatted output information