• Guest, The rules for the P & N subforum have been updated to prohibit "ad hominem" or personal attacks against other posters. See the full details in the post "Politics and News Rules & Guidelines."

Two batch files. One disables NIC and enables wifi card. The other enables NIC and disables wifi card. Combine them?

Synomenon

Lifer
Dec 25, 2004
10,530
5
81
So I have two separate batch files. One to disable the NIC and enable the wifi card:

@netsh interface set interface name="Ethernet" admin=disabled
@netsh interface set interface name="Wi-Fi" admin=Enabled


and another to do the opposite (enable the NIC and disable the wifi card):

@netsh interface set interface name="Wi-Fi" admin=disabled
@netsh interface set interface name="Ethernet" admin=Enabled



How do I combine them into one batch that I can double click to toggle one way and double click again to toggle the other way?
 

ASK THE COMMUNITY