简体   繁体   中英

Problems trying to change from Framework 4.0 to 3.5 .NET

I have a project done with. NET Framework 4, and I need to add some libraries which work on the Framework 3.5, so I changed my project to Framework 3.5, now the project recognizes the libraries, but it shows an error similar to this:

Error 2 Object reference not set to an instance of an object.

and this is in each. resx I have in my project, how can I resolve this?

Seems like this will work for you...

  1. Open Form in Designer and make needed GUI changes. Close designer and save
  2. Compile project and receive RESX compile error (only forms with Imagelist should have this problem)
  3. Double-click resx compile error to open resx file.
  4. Scroll to top of imagestream.
  5. Edit the top line of the Image stream: AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w TO AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w
  6. Close and save resx file and recompile.

**NOTE: the only difference are the characters at end "j00LjAuMC4w' to "j0yLjAuMC4w"

Got this solution from Microsoft Connect website. Thanks to them.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM