Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

Visual Basic 2010 build problem - National Instruments.Common targeting AMD64

My Visual Basic program uses some Measurement Studio controls and all works well on my development machine.  Having added a Setup Project I get an error message

 

File 'NationalInstruments.Common.Native.dll' targeting 'AMD64' is not compatible with the project's target platform 'x86'

 

How do I change it to target a generic "x86"?

 

Thanks.

0 Kudos
Message 1 of 3
(3,087 Views)

Hi Indiana_Bill,

What platform is your original project targeting in Visual Studio? For example, are you targeting x64, x86, or AnyCPU? 

If you specifically want to target x86, you would need to make sure your references are pointing to the 32-bit versions of the National Instruments assemblies or platform-agnostic versions (AnyCPU). To my knowledge, the assembly you refer to should be platform agnostic.

Where are your references for that assembly pointing? Are they pointing to the Global Assembly Cache, and if so are they pointing to GAC_64?

The following documents might be helpful in understanding the differences.
http://zone.ni.com/reference/en-XX/help/372636F-01/mstudiowebhelp/html/64bitsupport/
http://zone.ni.com/reference/en-XX/help/375857A-01/xml/64bitcore/

As a sanity check, can you target your project to explicitly use the x64 or AnyCPU options and see if the same message appears?

Charlie J.
National Instruments
0 Kudos
Message 2 of 3
(3,052 Views)

The application was intended to target x86.  It had a mixture of setting, some "x86" some "Any CPU".  I finally found one last setting to change to "x86" and built successfully this morning.  I knew it was something of that sort of problem but couldn't find the key setting.

 

Thank you for your help.  I will review the suggested references to improve my understanding.

0 Kudos
Message 3 of 3
(3,046 Views)