Solved

VBA & LDAP Query get object's properties

Posted on 2014-01-22
4
970 Views
Last Modified: 2014-01-23
Need a function! It gets computer name and returns property from Active Directory on my choice like description or whenCreated.

I have several OU to look into so all of them are needed to be put into the code of function:
eur.mydomain.com/FRP/SMZ/SMZ Workstations 7/
eur.mydomain.com/FRP/SMZ/SMZ Workstations 7 Lite/
eur.mydomain.com/FRP/SMZ/SMZ XP Workstations/
eur.mydomain.com/FRP/SMZ/SMZ XP Workstations/SMZ XP Lite Client Base Workstations
eur.mydomain.com/FRP/SMZ/SMZ XP Workstations/SMZ XP Lite Client Base Workstations/SMZ XP Lite Client Shared User Workstations/
0
Comment
Question by:DoubleLeft
  • 2
  • 2
4 Comments
 
LVL 65

Accepted Solution

by:
RobSampson earned 500 total points
Comment Utility
Hi, have a look at this macro enabled workbook.  If you put your computer name in column A, and the attribute names you want in row 1, then run the GetData sub, it will populate those cells with the information for each computer.

Regards,

Rob.
Get-Computer-Attributes-From-Nam.xlsm
0
 

Author Comment

by:DoubleLeft
Comment Utility
Thank you so much!
0
 

Author Closing Comment

by:DoubleLeft
Comment Utility
Thank you so much!
0
 
LVL 65

Expert Comment

by:RobSampson
Comment Utility
No problem. Thanks for the grade.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

771 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now