Error after switching from .NET 3.5 to 4

Posted by Queops on Stack Overflow See other posts from Stack Overflow or by Queops
Published on 2010-12-27T17:07:58Z Indexed on 2010/12/27 17:54 UTC
Read the original article Hit count: 208

Filed under:
|
|
Application.Run(new Main());

This line gives TypeInitializationException was unhandled after I switched from 3.5 to 4 framework.

Why is this?

Edit: Forgot to mention this is a Winforms C# application.

Okay so I have SQLite .NET referenced. I tried this on a project created on .NET 4 by default and didn't give me any error so I assumed it wasn't about SQLite .NET http://sqlite.phxsoftware.com/

Please note v2.0.50727 this is the runtime version of the DLL which seems to be causing the problem.

  • Thrown: "A assemblagem de modo misto foi criada com base na versão 'v2.0.50727' do tempo de execução e não é possível carregá-la no tempo de execução 4.0 sem informações de configuração adicionais." (System.IO.FileLoadException) Exception Message = "A assemblagem de modo misto foi criada com base na versão 'v2.0.50727' do tempo de execução e não é possível carregá-la no tempo de execução 4.0 sem informações de configuração adicionais.", Exception Type = "System.IO.FileLoadException"

Seems he can't run the DLL on v4 with/ extra configuration.

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET