As an alternate solution, I've installed VS 2019 and the problem does not happen. Something is definitely up with the newest VS 2022 update. I'm using .NET Core 2.2, but even if it's not supported, it shouldn't give me additional errors.
System.TypeLoadException: 'Method 'GetItem' in type 'Microsoft.AspNetCore.Mvc.Razor.Internal.FileProviderRazorProjectFileSystem' from assembly 'Microsoft.AspNetCore.Mvc.Razor, Version=2.2.0.0, ...
Pier-Luc Allard
1
Reputation point
Hi there,
Since the last Visual Studio 2022 update, I've been having the error on my application and can't seem to make it disappear for some reason.
The error is pretty straight forward, it's missing a reference to Mvc.Razor version 2.2.0.0. So I've added it using NuGet, but no luck, I still get the same error. Does anyone know what's happening? Any help is appreciated, and I can provide other details if requested.
Thanks!