Main Site login Signup

BadImageFormatException when creating custom user control with Awesomium browser

Creating a custom user control that limits and controls what the Awesomium browser control does. The functionality of the control is specific to a few applications that are being built so that is why I want to build a custom user control versus reusing the same code over and over in different projects. Furthermore it is far easier in the applications to load the custom control on the form and set a few public properties on the control than it is to copy a bunch of code and make changes to multiple projects when changes are needed.

For the user control project I have select x86 as the target platform as I well know that that is the only target that Awesomium as been built for thus far.

When creating a NEW user control project, changing the target to x86, simply adding the Awesomium browser to the project, and trying to build (run) the project I receive the following error:

An unhandled exception of type 'System.BadImageFormatException' occurred in mscorlib.dll

If I remove the browser control and add any standard control, i.e. textbox, checkbox, etc, the user control builds (runs) just fine.

I have tried changing the .NET version that the user control uses to anything from 2.0 to 4.6 and nothing helps.

The research I have done tells me that the Awesomium dll file(s) don't conform to common language runtime expects.

Question 1: What is causing this error and how can I fix it????

Question 2: Also a few years ago there were hints that the Awesomium team was working on a x64 version. Is this true? If so any idea of a release date?

asked Sep 01, 2016 at 04:23 PM avatar image MikeT 0
more ▼
(comments are locked)
10|1100 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.