Basic Powershell

I want to get local groups (get-localgroup) on a server and the members (get-localgroupmember) in those groups output to a file in a format like this.

Group name
Member
Member
Member

Group Name
Member
Member

Etc…

Kirk,

Welcome to the forum. :wave:t4:

That’s a nice task to practice. Good luck with it! :wink:

… or do you have any question?

Please keep in mind that we do not deliver ready to use code or solutions on request. We expect you to make an own attempt to solve a given problem. For such an easy task like this you should find at least a thousand examples already written. Use you favorite search engine and search for it. :wink: :+1:t4:

If you already have code you wrote your self and just got stuck with please post this code here (formatted as code) and describe what kind of problem you have with it and we will be happy to assist.

Have a nice christmas! :smiley: :santa:t4:

2 Likes