Solved

get ADuser by office

Posted on 2016-08-15
2
37 Views
Last Modified: 2016-08-15
How could search the ad for a user by the office field in the ad profile?
0
Comment
Question by:Roccat
2 Comments
 
LVL 83

Accepted Solution

by:
oBdA earned 500 total points
ID: 41756291
Replace the "*" with whatever you want to look for; "*" is a wildcard for zero or more characters, "?" for exactly one character.
Get-ADUser -Filter "physicalDeliveryOfficeName -like '*'" -Property physicalDeliveryOfficeName

Open in new window

0
 

Author Closing Comment

by:Roccat
ID: 41756299
Thank You!!
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
How to sign a powershell script so you can prevent tampering, and only allow users to run authorised Powershell scripts
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question