Unable to use any unity version. Keep getting an error.

The issue is simply as mentioned in topic. Can not use any version of unity or any project. Keep getting this error message. I tried updating, repairing Visual studio and unity. But still no luck. Error code is below,

Library\PackageCache\com.unity.ide.visualstudio@2.0.11\Editor\VisualStudioIntegration.cs(30,18): error CS0246: The type or namespace name ‘Messager’ could not be found (are you missing a using directive or an assembly reference?)

Any help is appreciated.

What version of the .NET framework do you have installed?

I have installed .NET4.8
I tried

I have installed .NET 4.8

I downgraded Visual Studio Editor 2.0.11 package from package manager to version 2.0.9 Then the error issue was fixed. But I had to do this to all the unity projects I’m using. Even after I start a new one.

Now I installed unity 2021.2 and I’m still getting the same error. The biggest issue is now I can’t downgrade Visual Studio Editor 2.0.11 package from package manager. So there is no work around.

Any help is Highly appreciated.