Jump to content

Use AutoIt to configure network IPv4 properties


Recommended Posts

I have to switch my laptop connections between a wireless connection and a direct network cable connection and I have to manually configure the network IPv4 properties each time. I want to use AutoIt to do this. However, the road to the IPv4 properties is quite lengthy (Start => Control Panel => Network and Internet => Network and Sharing Center => Local Area Connection => Properties => Internet Protocol Version 4 (TCP/IPv4) => Properties). Running Autoit to get there would result in lots of windows being popped up, then brought down again.

If there was a shortcut to the TCP/IPv4 properties window, it would be much better.

Perhaps I'm making this all too hard, and there's some registry settings I could export/import to do the configuration.

Link to comment
Share on other sites

You could use the Windows' built-in netsh command:

ShellExecute("netsh", 'interface ip set address name="Local Area Connection" static 1')

Edit: more info on the subject:


Edited by sleepydvdr

#include <ByteMe.au3>

Link to comment
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

  • Recently Browsing   0 members

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