Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

File or assembly NationalInstruments.DAQmx was not found...

I have an application running under VB2008 using the NationalInstruments.DAQmx.dll. Until now, everything run fine.

 

Now I installed Win7 64 bit on my computer and reinstalled all the NI software in the same way as before.

 

When starting my application now, I get the message (translated from German): The file or assembly "NationalInstruments.DAQmx, Version=9.2.35.32, Culture=neutral, PublicKeyToken=18cbae0f9955702a" or one of its dependencies was not found...

 

The file is still available and the path is set correct.

 

Any suggestions?

 

Thanks a lot in advance.

0 Kudos
Message 1 of 14
(9,163 Views)

Hello,

 

from the part of you post "translated from German" I guess that you are native german speaking, so am I. So if I am right with that, we can go on in german. 

 

Can you please verify in the software section of the control panel, that for the NI-DAQmx driver the support for the nesassary .NET frameworks are installed? (National Instruments>>Change/Remove>>NI-DAQmx>>Change)

 

Please keep me informed about the outcome.

 

Kind Regards,

Johannes Graeper

National Instruments Germany

0 Kudos
Message 2 of 14
(9,159 Views)

Hi,

 

thanks a lot for your reply.

 

Yes, I am German but maybe this could be of general interest, so let's keep it in English.

I won't be able to access the computer with the problem before Wednesday, but I can assure that I checked before that NET 2.0 and 3.5 frameworks and the NI-DAQ drivers are installed.

 

Any other ideas?

 

Regards

 

Axel

 

0 Kudos
Message 3 of 14
(9,157 Views)

Hi,

 

Now I tried to reinstall the whole NI-DAQ-Software.

 

During the deinstallation I got the message "Path N:\xxxx\bilder\ does not exist". I ignored that message.

 

When I tried to reinstall the NI-DAQ-Software I got the same message and the installation aborted.

 

 N:\xxxx\bilder\ is a path where I save my pictures. This path does still exist, I don't know why the installation process can't find it. Beside that I have no idea why the NI-DAQ Software needs to access that path.

 

Any ideas?

0 Kudos
Message 4 of 14
(9,141 Views)

Hello,

 

sorry for the delay, but unfortunately I fell ill.

 

I have no idea, why the installer is looking into that directory. Is it possible, that you ran the installer from that directory in first place?

 

But to get back to the original problem. Have you tried to install that assembly to the GAC? If not, you can do it with the tool gacutil:


Global Assembly Cache Tool (Gacutil.exe) 

http://msdn.microsoft.com/en-us/library/ex0ss12c%28v=vs.80%29.aspx

Only the assemblies installed in the GAC or located aside to your project can be found. Have a look to the following page too:


Kind Regards,

Johannes Graeper

0 Kudos
Message 5 of 14
(9,138 Views)

Hi Johannes,

 

thanks for your reply.

 

Unfortunately I will not be able to follow your suggestion before I get my NI-DAQ re-installed.

 

No the installation was not started from that dirctory, not even from that network drive. I installed it from the local hard disk.

 

Regards

 

Axel

0 Kudos
Message 6 of 14
(9,134 Views)

Hi Axel,

 

Johannes will be out of office for a few weeks. I took your case over.

 

I would like to ask something trivial but which could be interesting to try: Are you using the National instruments 64bits assembly or the 32 bits one? The 64 bits assembly can be found under C:\Program Files\National Instruments\MeasurementStudioVS2008\DotNET\Assemblies (64-bit) .

 

Best Regards / Mit freundlichen Grüßen 

______________
Florian Abry
Inside Sales Engineer, NI Germany
0 Kudos
Message 7 of 14
(9,124 Views)

Hi Florian,

 

when the software still worked there was no NationalInstruments.DAQmx.dll in ...DotNET\Assemblies (64-bit), so I took it from the 32-bit directory.

 

But all this won't help before I can't get the NI-DAQ reinstalled.

 

Regards

 

Axel

0 Kudos
Message 8 of 14
(9,119 Views)

Hi Axel,

 

Let me know after reinstall, it can either lay at the install of DAQMX or Measurment Studio (be sure to chose the elements to install manually). Here is how it looks by me:

 

daq net.png

 

Best Regards 

______________
Florian Abry
Inside Sales Engineer, NI Germany
0 Kudos
Message 9 of 14
(9,113 Views)

Another thing you may want to look at after you get the driver reinstalled is the driver version. Your application was built against DAQmx 9.2.35.32 assembly. Your application will need to reference this same version at runtime. It will not be able to run with a higher version like 9.4.35.xxx.

 

When running a .NET DAQmx application you need two things on the system. 1) The DAQmx driver, this includes some libraries and other low-level components that actually communicate with the devices. And 2) the DAQmx .NET assembly that the application was built with; this includes the API that .NET uses to communicate with the driver. This can be confusing because when you install the DAQmx driver, you also have the option of installing the .NET API, but that is only meant for developing application, not running them.

 

You can get the correct assembly in two ways. 1) copy the assembly over to the application directory on the new system from the development system. Or 2) include the DAQmx merge module in the installer that you are using to distribute the application. If you development system is no longer available, then you could also install DAQmx 9.2  and select to install the .NET API support. In that case, I would also recommend creating a copy of the assembly in the application directory so that you can update the driver without losing the assembly reference.

National Instruments
0 Kudos
Message 10 of 14
(9,095 Views)