Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources
Viewing all articles
Browse latest Browse all 6937

ADgroupMember script

$
0
0

Hi Guys,

I am learning powershell , This is basic script to display username, Displayname and title

 

$group=Get-Content'D:\New folder\list.txt'

 

 

Get-ADGroupMember

 

 

-Identity$group|

Where-Object

 

 

{ $_.objectClass -eq'user' } |

Get-ADUser

 

 

-Properties*|Select @{Name="NTID";Expression= {$_.MailNickName}},Displayname,Title

Actually i want include Group variable as well in output , Can you help how can i do it ?

 


Viewing all articles
Browse latest Browse all 6937

Trending Articles