Failed to load the file or assembly "xxx" or one of its dependencies, the found program list definition does not match the assembly or the Nuget package cannot be published

The first problem : Failed to load the file or assembly "xxx" or one of its dependencies, and the found program manifest definition does not match the assembly.
This problem is usually caused by the dll referenced by the current program block that is not included in your released program. Observe carefully to see which DLLs are missing.
The second question : Nuget package cannot be released.
Nuget
I encountered a painful problem at the beginning, which was to quote es in Nuget (a package will be generated to the project root directory). But the program cannot run when it is released. Prompt the first question as above. But there is something in the bin. Then there was an idea. Although it is a little bit unclear, the problem is solved.

  1. First delete all your Nuget packages here.
  2. Find the dll you need in the packages package in your root directoryFind the dll you need in the packages package in your root directory
  3. Then put it in the project bin, and add a reference. The solution is complete.

If not, you can comment and leave a message. If you can solve it, do your best

Guess you like

Origin blog.csdn.net/hello_mr_anan/article/details/100981028