question

Upvotes
Accepted
5 3 4 3

RFA Mismatch between processor architecture MSIL vs AMD64

I'm trying to build a C# assembly that uses the RFA library and I'm getting the following warning when compiling:

There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "RFA8_NET140_x64", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project.

The resulting program fails with exception:

System.BadImageFormatException: Could not load file or assembly 'RFA8_NET140_x64, Version=8.0.1.2, Culture=neutral, PublicKeyToken=07e17b14770d2d69' or one of its dependencies. An attempt was made to load a program with an incorrect format.

I'm working on Windows 7 using MS Visual Studio Professional 2015 Version 14.0.25431.01 Update 3

Any suggestions? Thanks.



treprfarfa-apimsil
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

1 Answer

Upvotes
Accepted
5 3 4 3

I finally solved this making sure that the aseembly was built using x64 architecture. I also had to ensure that the unit test framework also used x64 as the architecture.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Click below to post an Idea Post Idea