1

How to have Github open Visual Studio 2017 as an admin when opening a GitHub project? I get a null reference object error when GitHub opens Visual Studio then I have to restart VS with administrator rights. I couldn't find the Run as Administrator option in devenv.exe properties.

Update

enter image description here

Tony_Henrich
  • 42,411
  • 75
  • 239
  • 374
  • What do you mean by have *"Github open Visual Studio 2017"*? What is the exact error you are getting? Typically there is no need to run Visual Studio with elevated privileges. Letting websites launch applications with elevated privileges does not sound like a good idea. – user7860670 May 22 '18 at 08:01
  • See the 'Open in Visual Studio' button above. This used to work but now gives null object reference error at the top of the Team Explorer pane. I always run Visual Studio in elevated mode. VS is practically useless otherwise. The problem is happening on a Windows 10 machine. on a Windows 7 machine, Github launches VS as admin and works as expected. Not sure why you think VS should not run in elevated mode. – Tony_Henrich May 23 '18 at 00:38
  • What are you doing that requires VS to be in elevated mode? – Hong Ooi May 23 '18 at 00:44
  • One for me was I couldn't switch a web project from using IIS Express to IIS. Some error about no permission to access IIS metabase. Check some of the other reasons https://stackoverflow.com/questions/20261724/why-run-visual-studio-as-run-as-administrator. Google the issue and you'll find other reasons. – Tony_Henrich May 23 '18 at 04:40
  • I never run VS with elevated privileges. Also I've never seen "Open in Visual Studio" button. I guess both of these are somehow specific to aspnet development. – user7860670 May 23 '18 at 08:44
  • I run in elevated privileges so I don't encounter any issues and I can do whatever I want in Visual Studio. I am not concerned about security if that's what developers are concerned about. I get the "Open in Visual Studio" option in GitHub regardless of project type. Why would it if I can develop in VS in different languages and for different types of apps? – Tony_Henrich May 24 '18 at 02:57

0 Answers0