LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Snap7 + Ni Labwindows/CVI Errors

i was trying to link the snap 7 DLL file with labwindows and i keep get the same errors any idea please

2021-09-18 (3).png

Tama
0 Kudos
Message 1 of 4
(1,267 Views)

First, you should probably not try to compile the client, server and your own source file in the same project. The main problem is that the Snap7.h file uses a strange way to define its constants. That may work for C++ compilers, I'm not sure, but not for most C compilers.

 

Basically all those const declaration should either be defined as a preprocessor #define or externalized into their own source code file. There is no other sane way to do that to not require some exotic C compiler versions.

Rolf Kalbermatter
My Blog
0 Kudos
Message 2 of 4
(1,217 Views)

I know the post is old but if you're online please can you tell me how you add snap7 to cvi library 

0 Kudos
Message 3 of 4
(108 Views)

Interfacing a CVI program with Snap7 DLL is quite simple and I can share some code with you. I canot help you if you want to directly integrate Snap7 code into your program.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 4
(89 Views)