 I_B
		
			I_B
		
		
		
		
		
		
		
		
	
			05-30-2008 07:58 PM
I just created a small CS program to digital I/O on the NI6009 (USB) and NI6225 (PCI).   I get the following error when attempting to run it:
Could not load file or assembly 'NationalInstruments.DAQmx, Version=8.7.20.11, Culture=neutral, PublicKeyToken=4544464cdeaab541' or one of its dependencies. An attempt was made to load a program with an incorrect format.
at Test.NIDevice.Initialize(String deviceName)
at Test.MainForm._startDevice() in C:\Users\UserName\Documents\Visual Studio 2005\Test\MyApplication\TestIO\MainForm.cs:line 100
 
This is a pretty vague error, I’m stuck and asking if someone can explain how to go about resolving this problem.
 
Thanks,
 
Ian
 
			
    
	
		
		
		05-31-2008
	
		
		08:06 AM
	
	
	
	
	
	
	
	
	
	
	
	
	
	
 - last edited on 
    
	
		
		
		10-29-2025
	
		
		08:42 PM
	
	
	
	
	
	
	
	
	
	
	
	
	
	
 by 
				
		 Content Cleaner
		
			Content Cleaner
		
		
		
		
		
		
		
		
	
			
		
Hi Ian,
Best Regards,
05-31-2008 09:51 AM
Hello Jonathan,
Yes, I am running Vista Home x64
I will be able to look at this in more detail tonight. Having said that, I quickly set the platform to x86 (it was previously set to 'Any CPU') and I was able to run my application.
Very quickly, can NI-DAQmx not be compiled for a 64 bit processor?
Thanks,
Ian
05-31-2008 10:51 AM
05-31-2008 02:01 PM
Hello Jonathan,
This information was very helpful. I had assumed the NI user DLL's were 64 bit. One last question. I am able to compile the NI .NET examples using 'Any CPU' platform. How doe the C# compiler know to us only the x86 platform and not the x64 platform?
Thanks,
Ian