LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Should NI supplied include files be copied to project folders?

Solved!
Go to solution

I released a project compiled and distributed under a particular version of CVI [8.1.x].

Then sometime later, another person retrieved the project for maintenance and tried to compile it, they could not find the NI include files.

 

They came back to me!

The reason they could not compile the project was they were using CVI 9.x.

The project was looking for the include files in \Program Files\CVI81. Complaints went to the manager.

 

So, the question is of a standard practice nature.

Should the project file list point to the NI prescribed [installed] folder locations,

or should the necessary include files be manually copied into "local" project folders before release?

 

thanks

Scott Youngren

Northrop/Grumman Electronic Systems

 

 

0 Kudos
Message 1 of 3
(3,113 Views)
Solution
Accepted by topic author Scott Youngren

The short answer is no: NI include files should remain in their directory; the IDE should fix all paths by itself.

 

To come in more details:

  • #include directives should show only the file names, not the pathnames
  • All directives for NI core include files should go in bracket-style (e.g. #include <cvirte.h>)
  • Instruments include files should go in quotes-style (e.g. #include "inifile.h")
  • Your include files can go in the source folder or in other folders of your choice (see next item)
  • Edit the project options to set "Include paths" (i.e. folders where the include files are searched for): applied to all projects for instruments loaded as a library, specific to the current project for application-specific include paths

I have always managed my projects according to these rules and never had a problem in upgrading IDE version while developing. You will see that most of them are automatically set by CVI (e.g. when the system asks to include some file needed for some statement: it will use the correct style).



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?
Message 2 of 3
(3,109 Views)

Roberto

Yes, thank you.

That's the answer I was looking for to use as the argument for stating my case [hmm, to managers who might not know everything!]

I was insisting on preserving the NI folder locations.

But what I was missing was the <  >.

So thanks for the very quick response.

 

cheers

Scott Youngren

0 Kudos
Message 3 of 3
(3,102 Views)