Jump to content

Recommended Posts

Posted

Hi All,

I want to change the computer name and domain, but autoit not working in ControlClick.

OS is Win 10 Professional

Run("control sysdm.cpl,,1")-->Working
WinWaitActive("系統內容")-->Maybe working
ControlClick("系統內容","變更(&C)...","[CLASS:Button; INSTANCE:2]")-->Not working

 

image.thumb.png.3df324182c5dd9b9e2a3db696e950815.png

Posted

I would suggest using a command to do this instead of automating this through clicks. Changing the computer name can be done like this:

WMIC computersystem where caption='OLD_NAME' rename 'NEW_NAME'

And it sounds like the domain is usually set via group policy. It may be able to be changed in the registry, however. See this link.

All my code provided is Public Domain... but it may not work. ;) Use it, change it, break it, whatever you want.

Spoiler

My Humble Contributions:
Personal Function Documentation - A personal HelpFile for your functions
Acro.au3 UDF - Automating Acrobat Pro
ToDo Finder - Find #ToDo: lines in your scripts
UI-SimpleWrappers UDF - Use UI Automation more Simply-er
KeePass UDF - Automate KeePass, a password manager
InputBoxes - Simple Input boxes for various variable types

  • 5 weeks later...
Posted

In pure AutoIT, no need to know the old name of the system. JScript had created a function which I used with good success.

To join to domain, maybe this answer is the one to try:

Good luck!

Always carry a towel.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...