LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Invalid use of '__declspec'

Solved!
Go to solution

Hi, I am trying to compile a formerly builded project without changing anything. But I get the following error for function declarations in the header file.

 

 

int DLLSTDCALL DLLEXPORT Test_InitDevDll (int invertByteOrder);


"test.h"(36,16)   Invalid use of '__declspec'.

 

 

What can be the reason of this error?

 

 

0 Kudos
Message 1 of 3
(4,604 Views)
Solution
Accepted by topic author Rados

Try reordering it:

DLLEXPORT int DLLSTDCALL Test_InitDevDll (int invertByteOrder);

 

I assume you now use CVI 2013 with Clang which is more strict.

-----------------------
/* Nothing past this point should fail if the code is working as intended */
Message 2 of 3
(4,590 Views)

Thank you very much it fixed my problem. In fact on my pc both CVI 2013 and CVI 9.0 is installed. I was building the project with CVI 9.0 but it was still giving error. Can the cause be the engine of 2013 ?

0 Kudos
Message 3 of 3
(4,587 Views)