LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

build distribution error - WINNT.H

Solved!
Go to solution

When I go to build a distribution for my project I get an error for WINNT.H. It says:

    cviincludes.h - 20 errors

                  "WINNT.H"[523,10) syntax error; found 'indentifier' expecting ','.

 

In the WINNT.h it highlights a line    __inline ULONGLONG

 

Since this is my first project and the first time I've tried to create a distribution, I have no idea what to do next. If I go back in to my project, change build configuration back to debug, I can't build my project anymore. I get the same error as above. Any ideas?

 

Mike

0 Kudos
Message 1 of 8
(5,427 Views)

Hello Mike,

 

That error can happen because of the order of your include files. What you are going to want to do is to make sure to include your Windows SDK files before your CVI header files. Let me know if this works out for you and have a great day!

 

Best Regards,

 

Adam G 

National Instruments
Applications Engineer
0 Kudos
Message 2 of 8
(5,406 Views)

Hi Adam,

 

I did have a couple of includes before windows.h so I moved them and get the same error. Right now I've got:

 

#include <windows.h>


#include <utility.h>
#include <ansi_c.h>
#include <userint.h>
#include "toolbox.h"
#include <formatio.h>
#include "inifile.h"
#include <gpib.h>
//#include <analysis.h>
//#include "counter.h"
//#include <time.h>;

#include <cviauto.h>
#include <cvirte.h>    

#include "Sirius_rev1.h"
#include "DatalogControl.h"
#include "SerNum.h"
#include "lotID.h"
#include "Switches.h"
#include "TestControl.h"
#include "SetupControl.h"

 

I'm not sure what some of these are like cviauto.h, userinit.h, toolbox.h, and utility.h. It seems like I can comment out some of them and my .c compiles but I always get them same error when doing the distribution build.

 

Mike

 

0 Kudos
Message 3 of 8
(5,395 Views)

Hello Mike,

 

I was wondering if you are able to build one of the example programs? Also is this the only application you are having trouble with?

 

Best Regards,

 

Adam G 

National Instruments
Applications Engineer
0 Kudos
Message 4 of 8
(5,363 Views)

Adam,

 

I was able to build the gpibrx project. At one point it had a missing dependancy so I had to have the CVI install disk even though I had done the Check Module Depenancies which was ok.

 

This is my one and only project so I haven't had another application which worked ok.

 

Mike

 

0 Kudos
Message 5 of 8
(5,330 Views)

Hi Mike,

 

Please take a look at this Knowledge Base.  I know that you have completed most of the first part of the solution, but please try to complete the entire solution and see if it helps in your situation.

 

Thanks

Ryan T
National Instruments
Applications Engineer
0 Kudos
Message 6 of 8
(5,291 Views)

Ryan,

 

That seemed to work. As in part2, under Options>>Environment>>IncludePaths, I had two include paths under the Specfic category. I removed them and it builds the distribution.

 

It still asked me for the files for NILabWindows/CVI 9.0.1 Full Development System so I had to grab the disk and gets the files off of it. Is this normal or is there a checkbox or an include file that I'm supposed to have enabled in one of the menus?

 

Thanks,

Mike

 

0 Kudos
Message 7 of 8
(5,283 Views)
Solution
Accepted by topic author MikeD_3258

Hi Mike,

 

Thats good news the WINNT.H error has gone away.  The other issue you are seeing is expected behavior because it needs the original distributions in order to build the new distribution.  You can select the check box "Cache components included from this source" in order to have the distributions saved on the computer so that you do not need the disks in subsequent builds.

 

Thanks

Ryan T
National Instruments
Applications Engineer
Message 8 of 8
(5,258 Views)