Jump to content
water

Active Directory Example Scripts

Recommended Posts

Crayfish

Thank you for these exceptional detailed examples.

I just want to leave a note that these examples are extremely well cared for examples!

I will try it when I'm back at work.

Share this post


Link to post
Share on other sites
water

I'm glad you like them :D

I created them for my company and it is just a minor effort to make them usable for everyone.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
Neutro

I wrote 4 scripts that do the following:

- Get_AD_Groups_Excel.au3: creates an excel file containing all groups of an AD in different columns, each column containing all users that belong to these groups. The goal of this script is to easily see if there are some "unwanted" users in the different groups of your AD.

- Get_AD_Groups_Textfile.au3: same than above but with a textfile output, 1 line per group, users separated by a coma ",". The goal of this script is to export these informations into another software easily.

These 2 scripts require the file "sid.txt" to convert windows special accounts SID to readable english account names (this is an extract from microsoft website).

- Get_AD_Users_Excel.au3: creates an excel file containing all users of an AD in different columns, each column containing all groups that belong to these users. The goal of this script is to easily see if there are some "unwanted" groups that a user is a member of.

- Get_Ad_Users_Textile.au3: same than above with textfile output for exporting these informations to another software.

You need to run these scripts on a Windows domain administrator session to get it working, or modifify the AD_Connect() lines to include domain administrator login/password.

Special thank to water for helping me getting this done :)

Get AD groups and users informations.zip

Edited by Neutro

Share this post


Link to post
Share on other sites
water

Thanks a lot for this additional examples!


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
harbot

@Water Just to check if your link are still working, coz been trying to download the .zip files but im not able to open it

Error : Does not appear to be a valid archive

Share this post


Link to post
Share on other sites
water

@Water Just to check if your link are still working, coz been trying to download the .zip files but im not able to open it

Error : Does not appear to be a valid archive

Moved to the ">general help and support" thread because this is the "example scripts" thread.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
jcpetu

Hi Water, nice to talk with you again, I got a question for you, is it possible to get the remote logged on user with your AD script?, or can I write some field on the computer object with the logged on user?

Thanks in advance and regards.

Share this post


Link to post
Share on other sites
water

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
KLM

Danke


K L M
------------------
Real Fakenamovich
------------------
K L M
------------------
Real Fakenamovich
------------------

Share this post


Link to post
Share on other sites
water

Gerne. Glad you like the UDF :)


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
water

Version 1.4.0.0 of the UDF has been released.
Supports AutoIt 3.3.10.x plus adds a few new functions.

Please test before using in production!

For download please see my signature.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
water

Version 1.4.1.0 (Bug fix) of the UDF has been released.

Only runs with AutoIt 3.3.10.2 and later.

Please test before using in production!

For download please see my signature.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
water

Version 1.4.1.1 (Bug fix) of the UDF has been released.

Only runs with AutoIt 3.3.12.0 and later.

Please test before using in production!

For download please see my signature.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
kyo

Some of the examples (ADCG and ADCU) will not compile with the new versions of Autoit - the Excel functions have changed a lot since then...

Share this post


Link to post
Share on other sites
JLogan3o13

What version of AutoIt and what version of the UDF are you using?


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites
kyo

What version of AutoIt and what version of the UDF are you using?

​The latest, and the latest! :)

Autoit 3.3.12.0

AD 1.4.1.1

All the _Excel functions have changed since Water wrote those examples, and now it's impossible to compile them "as-is".  I'm trying to convert the _Excel calls, but I'm not very successful yet..

Edited by kyo

Share this post


Link to post
Share on other sites
water

I'm about to translate them so they work with the latest version of the AD UDF and AutoIt.
But don't hold your breath ;)


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
kyo

Thanks Water.  I'm finding those utilities useful at work (I'm using a version I compiled a few years ago), and I'm coming back to them to learn from the code, but I'm having difficulties with the _Excel code.   

I won't hold my breath, but I'll check regularly! :-)

Thanks!

Share this post


Link to post
Share on other sites
water

You still should be able to compile the example scripts with AutoIt 3.3.8.1 and version 1.4.0.0 of the AD UDF.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (2018-06-01 - Version 1.4.9.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2018-09-01 - Version 1.3.4.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
kyo

Yes I can, but I'm trying to avoid having two Autoit installs.   In this case I'm mostly trying to replicate the results in Excel by using the new _Excel_ functions in Autoit 3.3.12.0 (I'm now aware you are one of the authors of both AD.au3 and Excel.au3).  I'm having problems writing a 1D-array on a single row, which this simple line used to do:

_ExcelWriteArray($oExcel, $i + 2, 1, $Zf, 0, 1)

The _Excel_RangeWrite() function seems to be writing to consecutive rows by default.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×