AssemblyDependencyResolver not resolving

1.5k Views Asked by At

I'm trying to create a custom AssemblyLoadContext utilizing an AssemblyDependencyResolver in C# under Net Core 3.1 (Visual Studio 2019).

But while I can see AssemblyDependencyResolver as a public sealed class in the Object Browser, neither IntelliSense nor the source code editor will admit it exists (and I have a using System.Runtime.Loader statement in the file so it should be recognized).

I've never seen something like this. How do I go about creating an instance of AssemblyDependencyResolver?

1

There are 1 best solutions below

0
On BEST ANSWER

Per the comment in the question:

Targeting netstandard2.1 will not allow you to access the System.Runtime.Loader.AssemblyDependencyResolver class; only targeting netcoreapp3.0 or netcoreapp3.1 will do that.