In a legacy ASP.NET 3.5 WebForms application I added a Microsoft.SharePoint.Client dll for 2010 Sharepoint.
After removing it I can successfully build the project, but when accessing the page I get a System.BadImageFormatException.
I have removed all dependencies from the project(project files, config files etc.). Framework is the same it compiles against as before, and platform also. Any idea?