Jan 4 2008

Vista Hosts File, How to Edit Easily without UAC Block

Posted by cheyennejack at 1:39 PM
2 comments
- Categories: Windows Tips

Share this: del.icio.us digg StumbleUpon Facebook Technorati Fav Mixx Spurl newsvine Furl reddit Yahoo! My Web Wists Simpy BlinkList BlogMarks smarking Ma.gnolia MSN Live Google Bookmarks Segnalo diigo excites Netvouz

Since upgrading(?) to Vista several things have driven me bonkers including editing my hosts file. You can't just open it, edit it and save like you did in XP. Instead you must have a program, like Notepad, open and in the 'run as administrator' mode.
Simple enough right? No. Constantly I open the file, start editing it and then save only to find I was supposed to open Notepad first, in administrator mode, then search through and find the hosts file in a series of non-intuitive folders unless you live and breathe in the system32 folder.

You could turn off this security issues by disabling UAC, but I've been trying to live and learn with it, since the concept is sound, even if annoying.

Here's the Vista hosts file quick fix that lets you double click a shortcut, edit the file and move on.

1)Right-click your desktop (or any folder) select New -> Shortcut.
2)Where it asks for the location of the item put "C:\Windows\System32\notepad.exe C:\Windows\System32\drivers\etc\hosts". Click Next. (This assumes you want to use Notepad to edit and your hosts file is the default folder structure)
3)Name your shortcut. Something like "Vista hosts file" will work, whatever you choose. Click Finish.
4)Right-click your new Shortcut and select "Properties".
5)Click the "Advanced.." button in the lower right.
6)Checkmark "Run As Administrator". Click Ok. Click Ok.

Now you are set. Double-click your icon, Vista will automatically ask you for admin permissions, click continue, edit your hosts file, and whistfully save without permission errors popping up all over and causing you to have to start all over again, derailing the train of thought you were really trying to execute.

Share this: del.icio.us digg StumbleUpon Facebook Technorati Fav Mixx Spurl newsvine Furl reddit Yahoo! My Web Wists Simpy BlinkList BlogMarks smarking Ma.gnolia MSN Live Google Bookmarks Segnalo diigo excites Netvouz




Comments

Ozan K. BAYRAM

Ozan K. BAYRAM wrote on 08/06/09 8:28 AM

If you still cant modify the file. Try setting attributes of the hosts file. Sample solution:
http://www.emeksepeti.com/blog/post/2009/08/06/Changing-your-hosts-file-in-Vista.aspx
CheyenneJack

CheyenneJack wrote on 08/30/10 1:14 PM

This process works just fine for setting your hosts file on Windows 7

Write your comment



(it will not be displayed)