Always run Visual Studio as administrator on Windows 10

You might be working with a program that always require administrator privileges, such as a service listening on a port. Up to Windows 10, you just right clicked the devenv exe, and checked “always run as administrator” in the compatibility tab. But in Windows 10, the compatibility tab is missing for the Visual Studio exe. Why? No idea. But here’s how to fix it.

To just run the shortcut as admin : right click on the sortcut > in the “properties” tab, click “advanced”, then check “always run as administrator”. Simple, fast, easy.

If you want to run Visual Studio as administrator also when opening a .sln or .csproj file, it’s not so easy. Here are the logical, coherent, and easy to find steps to fix this: (labels translated to english from french, sorry if it doesn’t match)

  • Open the start menu, type “troubleshoot”, and open “check your computer state and solve problems”
  • On the bottom left, click “troubleshoot compatibility problems”
  • Click on “advanced” on the left then “run as administrator”
  • Click again on “advanced”, then uncheck “automatically fix”, then “next”
  • Search for Visual Studio in the list, then “next”
  • Make sure “fix the program” is checked, then “next”
  • Select “troubleshoot the program” (bottom option)
  • Check “the program requires additional rights”, then “next”
  • Click “test the programe” then “next”
  • Select “save the parameters for the program” then “close”

Easy, logical, simple. Thanks Microsoft!