Question

Not able to run as web-site in visual studio 2013

Could not load file or assembly 'Aurigma.GraphicsMill' or one of its dependencies. An attempt was made to load a program with an incorrect format.

Exception Details:

System.BadImageFormatException: Could not load file or assembly 'Aurigma.GraphicsMill' or one of its dependencies. An attempt was made to load a program with an incorrect format.

 
 Stack Trace: [BadImageFormatException: Could not load file or assembly 'Aurigma.GraphicsMill' or one of its dependencies. An attempt was made to load a program with an incorrect format.]
   System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +0
   System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +416
   System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +166
   System.Reflection.Assembly.Load(String assemblyString) +35
   System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +190  

Tried as suggested by Graphicsmill frequent asked questions forums for Web Application

How to Resolve BadImageFormatException. (http://www.graphicsmill.com/docs/gm/frequently-asked-questions.htm)

Any other suggestions to make web-site run in my local-machine through visual studio 2013 is really helpful.

Was it helpful?

Solution

I found the answer, need to change to Relevant Application Pool.

["An attempt was made to load a program with an incorrect format" even when the platforms are the same

Answered by Kalyan.

OTHER TIPS

There's a lot of information about this problem. Most of it is about a problem with 64-bit vs 32-bit. Well, my exact problem was I was using 64-bit Aurigma.GraphicsMill but my App pool (DefaultAppPool) had Enable 32-Bit Applications set to True which if you read the description on the bottom of the window says it makes your app run in 32-bit Mode. I was trying to run a 64-bit .dll from a 32-bit application.

enter image description here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top