Home > Community > Discussion Forums

Instrument Control (GPIB, Serial, VISA, IVI)

Showing results for 
Search instead for 
Do you mean 
Posts: 6

Correct reference to VisaNS

We are using the VisaNS .NET 2.0 assembly from a C# class library using VisualStudio 2005.
What is the correct way to reference the VisaNS and Common assemblys?
The examples in the MeasurementStudioVS2005 folder references the assemblies in C:\Program Files\National Instruments\MeasurementStudioVS2005\DotNET\Assemblies\Current\NationalInstruments.VisaNS.dll
I see two problems with this:
1) The VisaNS.dll is only installed in this location if the development support is selected when installing VISA. The dll will not be installed on non development machines.
2) There will be versioning issues. The development and production machines must use exactly the same VISA revision or are backward compatibility solved with binding Redirect or similar?
I see too alternatives:
1) Include the VisaNS.dll with the application and reference to the included dll. Will an older VisaNS dll work with newer VISA isntallations? Should the Common.dll also be included.
2) Reference the VisaNS.dll registrated in the GAC. For unknown reasons on some machines the VisaNS is not registred in the GAC. When new versions of VISA is installed, will all old revisions also be installed or are backward compatibility solved with binding Redirect or similar?
Hans Forssell