mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 There is a location column, but no location. Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 The "General" tab should look like: <domain><userid> <password> DC=microsoft,DC=com <servername>.microsoft.com CN=Configuration,DC=microsoft,DC=com<servername>.microsoft.com is optional. OK. Also where can I hard code the last three inputs in the General tab? Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 When the location column is empty then the property "location" in AD is empty. Or in which property do you save the location? To hard code the values i suggest an INI file. So the script remains flexible. I will post a new version. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 I am sorry. Location meaning which OU it is in...naming context. Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 It is creating the computer account, but I am getting this error. Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 This is what I have in the general tab. Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 Run ADAT at a PC which as a domain member and you'll see the needed values. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 I have uploaded a new version to post #11. Rename the attached .txt file to .ini and set the values in he .ini file to fill the "General" tab. N.B. The new version doesn't show the domain parameters any more. It only takes them from the ini file My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 ini file is working great. However I still get error when creating computer account. It does get created though. Then when i try to join it gives me an error and does not join. Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 The error code you get is a general error. In most of the cases it means: Missing permissions. Can you check with the AD admin that the user you have set on the "General" tab has the permissions to set permissions for a computer account? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 These are the permissions on the computer account I created with the tool. Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 Which user do you use to run the tool to set the permissions on the user account? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 Permissions on user account? I run the tool as local administrator. I put in my domain credentials into the tool. Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 To join a computer to a domain three steps are necessary:_AD_CreateComputer($sAD_OU, $sAD_Computer, $sAD_User) to create a computer account in the specified OU. $sAD_User is the user or group that will be allowed to add the computer to the domain (SamAccountName). This is a two step process. Create the computer and then set permissions on the computer account. The commands are executed with the credentials of the user specified for _AD_Open (in the case of ADAT the user specified on the "general" tab). If this user doesn't have the permission to change a computer account then you see errorcode you got above._AD_JoinDomain($sAD_Computer[, $sAD_UserParam, $sAD_PasswordParam]) to join the computer to the domain. UserParam and PasswordParam are optional and need to be used when the user who is running the script doesn't have the needed rights to join the computer to the domainReboot the computerI think the current problem is caused by the user connecting to the AD not having proper permissions to change a computer account. Could you try to connect to the AD as domain admin? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 I am not a domain admin. However, I can do anything I want to computer accounts with the credentials I am using. Link to comment Share on other sites More sharing options...
mik3 Posted January 11, 2012 Author Share Posted January 11, 2012 (edited) When logged in as myself, I can run the tool and I get no error creating computer accounts. However, When I log in as the local administrator on a newly cloned machine and use my credentials (in the tool), I get the error. Edited January 11, 2012 by mik3 Link to comment Share on other sites More sharing options...
water Posted January 11, 2012 Share Posted January 11, 2012 Thanks for this information! It's my fault not passing the credentials from the "General" tab to the function calls. I will post an updated version tomorrow! My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
water Posted January 12, 2012 Share Posted January 12, 2012 (edited) I have uploaded a new version to post #11.If this version still gives errors when creating the computer account:try to login using format "domainusername" on the "general" tab instead of "username"Insert "i$AD_Debug = 2" after the "#include <AD.au3>" line Edited January 12, 2012 by water My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki  Link to comment Share on other sites More sharing options...
mik3 Posted January 12, 2012 Author Share Posted January 12, 2012 I get the same error creating computer accounts. It does create it. When I join, I get this. I will do what you said in previous post.http://postimage.org/image/j0jrc7jkn/ Link to comment Share on other sites More sharing options...
mik3 Posted January 12, 2012 Author Share Posted January 12, 2012 I have uploaded a new version to post #11.If this version still gives errors when creating the computer account:try to login using format "domainusername" on the "general" tab instead of "username"Insert "i$AD_Debug = 2" after the "#include <AD.au3>" line #include<AD.au3>i$AD_Debug = 2or like this#include<AD.au3> i$AD_Debug = 2 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now