I have a batch file that modifies the hosts file so that I can choose between a dev server and a production server for a CRM application I am developing. On Vista, I have no problems. Win7, however, gives me an access denied problem AND doesn't let me set the batch file to always run as administrator.
I cannot right click > Run As Administrator, because the batch file accepts an argument; "on" to turn dev server on, and "off" to turn it off. So, it must be run from the command line.
How do I fix this?
I just want to type:
and have it work.