Using Unity 2019, I am getting the error below in the console on a fresh new project. Have tried reinstalling Visual Studio and Visual Studio Tools for Unity using the VS Installer. Have gone into preferences in Unity, and the external editor was not set, so have set this to the devenv.exe in my VS installation folder. Have googled around and can’t find any other advice!
Anyone able to help? It doesn’t flag as a critical failure, and double clicking a script in Unity does open it in VS. However, when I edit scripts in VS I don’t get autocomplete working and prompting me with Unity code, which Ben always gets in his lectures. Am guessing this error might be why?
Would really like to fix it, all help gratefully received!
Thanks.
Error detecting Visual Studio installations: ApplicationName=‘D:\My Documents\Matt’s Files\Unity Course (Udemy)\Test\Library\PackageCache\com.unity.ide.visualstudio@1.0.5/Editor/VSWhere/vswhere.exe’, CommandLine=’-prerelease -property productPath’, CurrentDirectory=’’, Native error= The system cannot find the file specified.
at System.Diagnostics.Process.StartWithCreateProcess (System.Diagnostics.ProcessStartInfo startInfo) [0x002dc] in :0
at System.Diagnostics.Process.Start () [0x0003a] in :0
at (wrapper remoting-invoke-with-check) System.Diagnostics.Process.Start()
at VisualStudioEditor.VSEditor+d__1.MoveNext () [0x00106] in D:\My Documents\Matt’s Files\Unity Course (Udemy)\Test\Library\PackageCache\com.unity.ide.visualstudio@1.0.5\Editor\VSEditor.cs:57
at System.Collections.Generic.LargeArrayBuilder1[T].AddRange (System.Collections.Generic.IEnumerable
1[T] items) [0x0005e] in :0
at System.Collections.Generic.EnumerableHelpers.ToArray[T] (System.Collections.Generic.IEnumerable1[T] source) [0x00033] in <b7efe7e6e548497fac3c4a6049a0a4b6>:0 at System.Linq.Enumerable.ToArray[TSource] (System.Collections.Generic.IEnumerable
1[T] source) [0x00018] in :0
at VisualStudioEditor.VSEditor.GetInstalledVisualStudios () [0x00099] in D:\My Documents\Matt’s Files\Unity Course (Udemy)\Test\Library\PackageCache\com.unity.ide.visualstudio@1.0.5\Editor\VSEditor.cs:231
at VisualStudioEditor.VSEditor…cctor () [0x00022] in D:\My Documents\Matt’s Files\Unity Course (Udemy)\Test\Library\PackageCache\com.unity.ide.visualstudio@1.0.5\Editor\VSEditor.cs:70
UnityEngine.Debug:Log(Object)
VisualStudioEditor.VSEditor:.cctor() (at Library/PackageCache/com.unity.ide.visualstudio@1.0.5/Editor/VSEditor.cs:74)
UnityEditor.EditorAssemblies:ProcessInitializeOnLoadAttributes(Type)