I have created a Powershell script which fetch security group Members of specific account from multiple remote servers. But, the output I am getting is annoying. Assume group member as Server_Admins, Server_Admins1 and so on, then I want output as below:
PowerShell’s formatting system will produce a table when you give it less than 5 properties, by default. If you want something other than that, you’re going to need to code it out yourself. You’ll have to enumerate each one and output whatever you want.
Output formatting is frankly not PowerShell’s strongest superpower - if you want anything more than the default, you end up having to code it up yourself.