How to always run applications as administrator in Windows 8

I recently got a new laptop with Windows 8. I’ve been trying to not hate the removal of my start menu too much. One of the changes they also made, is that User-Account-Control can’t really be disabled without a registry change– and if you make that registry change, most of the Metro/Modern UI apps will no longer work! Having certain applications not run as administrator can really be a problem, however… Visual Studio needs admin access to create IIS web applications, for instance. Additionally, shelling out to cmd.exe for doing a multitude of different things will be very frustrating when you don’t have those admin privileges that are rightfully required to do administrative things…

Unfortunately, there’s no easy GUI way to tell Windows 8 to always launch applications as an administrator. You can right click on a shortcut and select ‘run as admin’ each time– or even define a shortcut and set ‘run as administrator’ on the compatibility tab– but this doesn’t work if you use start->run->’cmd.exe’, such as I do… It also doesn’t work if you’ve pinned solutions to your task bar, such as I do for Visual Studio.

Thankfully, after some searching, I found a solution. You can have any executable on your computer run as admin(assuming you have permission to do so), by adding entries to this registry key:

HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers\

Simply add a new string value, paste the full path to the executable(such as c:\windows\system32\cmd.exe), and then edit the value to say ‘RUNASADMIN’. Next time you start that executable– through a shortcut, by going to start->run, through entries pinned to your taskbar, or double-clicking on an associated file in explorer, Windows 8 will actually run it as an admin, as you require.