Unity can't open VS2019

Not sure if i can post Unity with Visual Studio problems here but the Microsoft feedback/forums don’t respond so i’m doing it here…

My Visual Studio 2019 needs to be ran as administrator in order to work for some reason, therefore Unity can’t launch it (for example when i click open a script) and therefore i can’t work on projects. Whenever i try to open it without administrator it says “Unknown Error” and a file path to the visual studio activity log. After looking at the activity log i saw “Failed to initialize Registry Root Hive” and “ACCESS DENIED”. That’s how i knew to launch it with admin but again, i can’t use it with unity.

And yes, i have tried re-installing.
Is this happening to anyone else or does anyone have a solution? Help would be very much appreciated.

That seems to be an issue with VisualStudio. I’m still running on 2017 with no errors. See if you can find that and if that fixes it.

I uninstalled VS2019 and got 2017 and i’m getting the same error… Am i doing something wrong?

I think it’s because since the user i use and always used is an Administrator, visual studio doesn’t have access to the “Registry Root Hive” unless it is run as Admin. I have no idea why VS needs the registry thing but it’s very frustrating. Is there a way to give visual studio and unity Administrative permissions or something? (launching unity with admin doesn’t solve the issue)

I wouldn’t know. This is a first for me.