I built an application to measure current consumption from a device in Visual Studio 2012. I built a library for the National Instruments USB-6008 and added the dll from C:\Program Files (x86)\National Instruments\MeasurementStudioVS2012\DotNET\Assemblies\Current, which is 9.9. Everything ran smoothly on my dev machine so I pushed all changes to the production server, which is packaged as a Click-Once app.
On the machine running the actual Click-Once app, I downloaded and installed the driver fir 9.9 from here: http://www.ni.com/download/ni-daqmx-9.9/4707/en/. When the application gets to the point where it measures the current consumption, I get the error:
System.BadImageFormatException: Could not load file or assembly 'NationalInstruments.DAQmx, Version=9.9.45.39, Culture=neutral, PublicKeyToken=4febd62461bf11a4' or one of its dependencies. An attempt was made to load a program with an incorrect format.
File name: 'NationalInstruments.DAQmx, Version=9.9.45.39, Culture=neutral, PublicKeyToken=4febd62461bf11a4'
What am I doing wrong?