Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

NI Visa C# Libraries

Is there a version of the libraries that work with .Net Core?  The dlls and example code are all in .NetFramework.  I tried to add them (Ivi.Visa.dll and NationalInstruments.Visa.dll) as assemblies in my .NET Core project and the ResourceManager class works fine for finding resources.  Once I try to get a MessageBasedSession though, I get an System.IO.FileNotFoundException - Could not load file or assembly NationalInsturments.Common, Version=13.5.40.173 Culture=neutral  The system cannot find the file specified

Message 1 of 7
(4,654 Views)

You may want to look here:

 

https://forums.ni.com/t5/Measurement-Studio-for-NET/Ni-DAQmx-NET6-Support/m-p/4298564#M21998

 

It's basically a .Net Interop library for the C DLL of NI VISA (which I suppose is the VISA .Net Framework also, but precompiled as .Net Framework library so not compatible with .Net Core).

Rolf Kalbermatter
My Blog
Message 2 of 7
(4,609 Views)

Will give this a look.  Thank you!

0 Kudos
Message 3 of 7
(4,593 Views)

I ended up converting the project to .Net Framework.

0 Kudos
Message 4 of 7
(4,523 Views)

Hi, did you trying the latest NI-VISA 2023 - Q4 to see if this fixed the issue?

We are desperate to move to .NET 6 or probably 8 now

0 Kudos
Message 5 of 7
(4,201 Views)

I had to redirect my focus to other projects for the past few months.  I will be picking this project back up in January more than likely.  I will grab the latest version of NI-VISA and and post my findings here.  My life would have been much easier if I could have used .Net Core over Framework for sure, so I feel your pain.

Message 6 of 7
(4,197 Views)

Hello, we have/had the same problem. Our SOLUTION was to switch the plattform to x86. after that, we were able to compile und run the programm without the error message. I hope this helps someone. Best regards.

0 Kudos
Message 7 of 7
(912 Views)