C # failed to load a file or assembly

Source: Internet
Author: User

  1. Recently do the project encountered this problem, Goole, Baidu a half-day, finishing the following several possible:
  2. DLL file name is inconsistent with the DLL file name at load time.
  3. DLL file does not exist at all, that is, the loss occurs,
  4. Load DLL path error, dll file exists, but the load path is incorrect
  5. Assembly version error. I A.dll internal references to the B.dll is version 1.0, and the performance of the B.dll is a 2.0 version, so the Winfrom design interface reported this can not find a dependency error.
  6. The main reason is that the referenced project. NET version differs from the startup framework. In my project, the original is VS2008 is the. NET3.5 framework, and later upgraded to VS2010, but has not changed the framework, some programs after the upgrade is not a problem, some upgrade after the compilation through, a run on the prompt" failed to load the file or assembly .... ", change to the corresponding VS version of the. NET4.0 can be run!
  7. 64-bit or 32-bit platform problem, default select any CPU, change X86 or X64 look;
    1. The main reason is that the referenced project. NET version differs from the startup framework. In my project, the original is VS2008 is the. NET3.5 framework, and later upgraded to VS2010, but has not changed the framework, some programs after the upgrade is not a problem, some upgrade after the compilation through, a run on the prompt" failed to load the file or assembly .... ", change to the corresponding VS version of the. NET4.0 can be run!

C # failed to load a file or assembly

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.