could not load System.ComponentModel.AsyncCompleteEventArgs

Question: How do you resolve "could not load System.ComponentModel.AsyncCompleteEventArgs" in Asp.Net Core 3.1 after publishing?

Login to See the Rest of the Answer

This error is normally thrown by SQL.Client DLL (Library). In order to resolve this, you will need to publish your project with a "Trim unused assemblies (in preview). The reason why the error happened is that you might have updated all the Nuget Packages and then when publishing the app, Visual Studio 2019 trimmed the updates from the Library.

Even when other Developers did not really come up with a solution to solving any specific error, the cause might be the same or related.


© 2024 - ErnesTech - Privacy
E-Commerce Return Policy