Link to home
Start Free TrialLog in
Avatar of AXISHK
AXISHK

asked on

List AD user with Powershell

Any idea how to list out all active users in AD with title contain either Director or Manager ?

Thx
Avatar of Ben Hart
Ben Hart
Flag of United States of America image

Pulling from memory, which might be spotty at this hour...


Get-adviser -filter * -properties title -eq director or
Avatar of AXISHK
AXISHK

ASKER

Doesn't work...

PS C:\Users\administrator.xxxxxx> Get-adviser -filter * -properties title -eq director
Get-adviser : The term 'Get-adviser' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ Get-adviser -filter * -properties title -eq director
+ ~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Get-adviser:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException
Sorry I'm
Mobile..

Get-ad user -filter * (-properties title -eq "director" or "manager")
SOLUTION
Avatar of Ben Hart
Ben Hart
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of nashiooka
nashiooka

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of AXISHK

ASKER

Thx