Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is there a better method than bat file to do this in win 7 1

Status
Not open for further replies.

AndyH1

Programmer
Jan 11, 2004
350
GB
I'm running a 64 bit version of windows 7. One issue I'm having is trying to disable the Microsoft Virtual WiFI MiniPort Adapter which keeps coming back even if I attempt to remove it. If I don't get rid of it I get errors and it keeps coming back (being rediscovered) when I reboot. I can disable them in the device manager, but they seem to slow down my speed (not sure why), removing them completely seems to work best, but I only seem to be able to do this temporarily, each reboot they come back.

Ive written a bat file which I put in the startup directory which runs the following
netsh wlan stop hostednetwork
netsh wlan set hostednetwork mode=disallow

This works but is very distracting getting a cmd box up on the screen each login. I wondered if there's a better way I could get win 7 to do this each time I log in, that is 'invisible' to the user, for example setting up a task. Looking at tasks though it only seems to give running a program, email or display a message, not run a script

 
Call the batch file from a WSH script

Code:
CreateObject("Wscript.Shell").Run "batch.cmd",0,True

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top