Static IP and dynamic IP switching
Applies to: The network environment of the company School Family Switch "please modify the specific IP address"
:: IP for Win7.bat
:: Win8 above please replace ip@echo off with IPv4Echo 1set to static IPEcho 2set to dynamic IP set/P answer=if%answer%==1Goto1 if%answer%==2Goto2 :1netsh interface ip set address"Local Connection"Static222.222.222.222 255.255.255.0 222.222.222.1netsh interface ip set DNS"Local Connection"Static192.168.10.8primarynetsh Interface IP Add DNS"Local Connection" 192.168.10.9Pausegoto End:2netsh interface ip set address"Local Connection"dhcp netsh interface ip set DNS"Local Connection"DHCP Pause
ADSL dialing
Add boot entry to enable automatic dial-up internet access
:: Adsl.batcd c:\windows\system32rasdial Broadband Connection account Passwordpause
Wireless AP Boot
No need to install software to realize notebook shared WiFi
:: Wireless AP Launcher program. Bat@echo offtitle WIN7 Virtual ap function: OKEcho. ECHO option 1, activate the wireless AP feature and only need to run once. Once run, you will not have to run it later. ECHO option 2, after you run option 1, run option 2. ECHO in the ADSL attribute, "Allow other Internet users to connect through this computer's Internet connection" tick, select local connectivity 12, and then the below "Allow other Internet users to control or disable the Internet connection," "Uncheck the link.". ECHO option 3, if you are not in need of a wireless network, run option 3. Echo 1. Turn on the WIN7 virtual wireless AP FeatureEcho 2. Bearer NetworkEcho 3. Exit the Hosting networkEcho 4. Display deviceEchox. ExitEcho. Set/P variable=Please enter the corresponding serial number (enter X key to exit):if%variable% = =1Goto A1if%variable% = =2Goto A2if%variable% = =3Goto A3if%variable% = =4goto A4if%variable% = =x Goto EXIT:A1Echostart setting up virtual APs, wait a moment .... netsh wlan set hostednetwork mode=allow ssid="Ssid-name"Key=password12345678goto:ok:a2clsnetsh WLAN start Hostednetworkgoto:ok:a3clsnetsh WLAN stop hostednetworkgoto:ok:a4clsnetsh WLAN show H Ostednetworkgoto:ok
Windows Network Configuration Script