whowd Posted May 5, 2006 Share Posted May 5, 2006 Here is a utility to help users joining a computer to an Active Directory domain. It provides similiar functionality to the netdom.exe utility in that it was designed to allow you to specify an OU (organizational unit) when you're joining the domain.Download:http://www2.truman.edu/~whowd/blog/2006/05...omain-tool.htmlRequirements:Latest Beta version of AutoITScreenshot: Link to comment Share on other sites More sharing options...
Valuater Posted May 5, 2006 Share Posted May 5, 2006 Welcome to The Forums... Very, Very nice for a first post! We look forward to GREATness from you!! Valuater 8) Link to comment Share on other sites More sharing options...
GaryFrost Posted May 5, 2006 Share Posted May 5, 2006 nice, a couple of suggestions tho instead of hard coding the user name and password in, maybe something like: $adUsername = InputBox("User","Admin Name:") If @error Then Exit $adPassword = InputBox("Password","Admin Password",'','*') If @error Then Exit an enhancement also would be to have an ini file for other vars that would need to be different on other networks such as $adDefaultContext, $adDomainController, $adDomain Gary SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted May 5, 2006 Moderators Share Posted May 5, 2006 (edited) Very nice script, I can tell you put a lot of work into this. A couple of suggestions:Have an option for it to prompt for a computer name, rather than using the one currently assigned.Have an option for it to prompt for the username and password, for security reasons.Edit: was a little slow on the second suggestion Edited May 5, 2006 by big_daddy Link to comment Share on other sites More sharing options...
whowd Posted May 5, 2006 Author Share Posted May 5, 2006 Thanks for all the feedback. I did a minor update to this script that will let it prompt you for the credentials (username and password) if they are not hardcoded.I believe in most enviroments the Active Directory structure would be fairly simple (small forest, one domain, etc) so adding in support for more complicated enviroments might be overkill and might confuse the average user. If someone needs to support multiple configurations, it should be easy enough to compile a few different versions of the script.Download Version 1.1:http://www2.truman.edu/~whowd/blog/2006/05...omain-tool.html Link to comment Share on other sites More sharing options...
mrrlg Posted May 5, 2006 Share Posted May 5, 2006 Wonderful work, my compliments. I have a little problem with line 279 and I am certain it has to do with how my domain is laid out. I receive this error at: $treeIDArray[$treeID] = $fullOU ^ =Array variable has incorrect number of sub scripts or subscript dimension range exceeded. Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted May 5, 2006 Share Posted May 5, 2006 thats cuz u need the latest beta, but wow very nice for a first post amazing what people can do if they READ the helpfile and look at examples on the forum Link to comment Share on other sites More sharing options...
mrrlg Posted May 5, 2006 Share Posted May 5, 2006 I upgraded from beta version 3.1.1.104 to 3.1.1.122 and generated the exact same error at line 279. $treeIDArray[$treeID] = $fullOU ^ =Array variable has incorrect number of sub scripts or subscript dimension range exceeded. Perhaps you might have another idea. Link to comment Share on other sites More sharing options...
whowd Posted May 6, 2006 Author Share Posted May 6, 2006 Do you see the TreeView start to populate with your OU's? Try changing the "2" in line 240 to a "4" and see if that helps your problem. From: Dim $treeIDArray[uBound($reversedAllOUsArray)*2] To: Dim $treeIDArray[uBound($reversedAllOUsArray)*4] Link to comment Share on other sites More sharing options...
ptrex Posted May 7, 2006 Share Posted May 7, 2006 Nice job !! This is sure welcome to add to list of tools that I will use. Keep up the good work. Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New Link to comment Share on other sites More sharing options...
DirT Posted October 18, 2006 Share Posted October 18, 2006 This is a very cool script and I am trying to use it at my work. However, I keep getting a $joinDomainResult = 1355 which I looked up and found this: 1355 Error Which means failure to find or connect to a domain controller. But the weird thing is that is finds/queries the Domain controller fine. Can anyone help ? Thanks Link to comment Share on other sites More sharing options...
DirT Posted October 18, 2006 Share Posted October 18, 2006 This is a very cool script and I am trying to use it at my work. However, I keep getting a $joinDomainResult = 1355 which I looked up and found this: 1355 Error Which means failure to find or connect to a domain controller. But the weird thing is that is finds/queries the Domain controller fine. Can anyone help ? ThanksNevermind, I figured it out Link to comment Share on other sites More sharing options...
lyledg Posted December 3, 2006 Share Posted December 3, 2006 One of the best and most useful scripts I have seen in a very long time! GREAT work!!! Link to comment Share on other sites More sharing options...
waelshawkat Posted February 8, 2007 Share Posted February 8, 2007 Nice work dear everything worked fine with me , but when i clicke Join Domain it gives me below error: MsgBox(0, "Domain Join Failed (" & $joinDomainResult & ")", "I wasn't able to join the domain successfully." & @LF & @LF & _ $joinDomainResultText) MsgBox(0, "Domain Join Failed (" & $joinDomainResult & ")", "I wasn't able to join the domain successfully." & @LF & @LF & ^Error Error: Variable used without being declared. how can i fix that? Link to comment Share on other sites More sharing options...
surreal Posted November 14, 2007 Share Posted November 14, 2007 does anyone know if there is a way to change the code so that it will only list one or two ou's within our ad network. at this time we have about 20 groups setup in our ad and i dont want the desktop tech to see them all. i would like for this to just list one group example: workstations but not servers, maybe just laptop and desktops. thanks for your help all.. d@ve Link to comment Share on other sites More sharing options...
surreal Posted November 15, 2007 Share Posted November 15, 2007 (edited) i was reading through my post and thought maybe i should try and make this more clear. i would like to just list one organizational unit within our ou. useing an example from the above image, once i login in i would like to only see "Academic Divisions" and then any group listed below it. i dont want to be able to see "Academic Affairs" or "Advancement" or "Bussiness Office". thank you... d@ve Edited November 15, 2007 by surreal Link to comment Share on other sites More sharing options...
surreal Posted November 15, 2007 Share Posted November 15, 2007 i go it... all i needed to change is... $adDefaultContext = "OU=Academic Divisions,DC=Domain,DC=COM" Link to comment Share on other sites More sharing options...
Jeff146 Posted June 2, 2008 Share Posted June 2, 2008 (edited) Does anyone know how to put the full domain controller string? For example: Right now I have the following: $adDefaultContext = "DC=ca,DC=test,DC=com" $adDomainController = "ca.test.com" $adDomain = "CA" If it was accessed within the network, then CA would work fine but if I were to add another computer to the domain through another computer I would need to put ca.test.com but unfornuately I couldn't get it to work. Does anyone know how I can modify it to do that? Thanks, Jeff Edited June 2, 2008 by Jeff146 Link to comment Share on other sites More sharing options...
pinoyz Posted July 9, 2008 Share Posted July 9, 2008 Very nice script, I can tell you put a lot of work into this. A couple of suggestions:Have an option for it to prompt for a computer name, rather than using the one currently assigned.Have an option for it to prompt for the username and password, for security reasons.Edit: was a little slow on the second suggestionHi!!!Any updates related to big_daddy's suggestion to Have an option for it to prompt for a computer name, rather than using the one currently assigned?I need this also. Hope you can help.Thanks in adv.Pinoyz Link to comment Share on other sites More sharing options...
weaponx Posted July 9, 2008 Share Posted July 9, 2008 The original poster most likely isn't going to respond. His last post was May 5th 2006. Besides, the changes that you need are very simple. 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