Sorry for the delay. I basically has to set up a Virtual Machine running Win 10, VS 2017 and NI Drivers to check what kind of compile error you were facing
Microsoft have a free virtual machine image with VS 2017 pre-installed, its a 65 day evaluation version, but its good enough for most work
https://developer.microsoft.com/en-us/windows/downloads/virtual-machinesPrerequisite:
1. Win 10
2. Visual Studio 2012-2017
3. NI Drivers (both NI 488.2 and NI Visa)
4. GPIB Hardware, I am using GPIB-USB-HS+ (kind of a overkill, but I suppose any NI based GPIB hardware works, Agilent usb devices works too)
Step 1: Install all the drivers obviously
. But when NI drivers are being installed make sure you are installing all the development framework related drivers too, these are not installed by default.
Step 2: Open TestVisa.sln, on the codes section, notice all those squiggly red line, these is because the reference's are not added to the project.
So goto project->add reference hit browse and point it to the reference(attached in the post earlier). It should look like in the picture:
Step 3: Compile and Test
I tested with my 34410A, It has GPIB and LAN
. The visa string is subject to change based on instrument but here is mine
1. GPIB, visa string was : GPIB0::15::INSTR
2. TCPIP, visa string is TCPIP0::a-34410a-14983::inst0::INSTR
Next up, I will modify the software to work with the latest NI 2017 Driver. Version 2 to come, right after I get windows 10 to work without crawling