LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

use of ftime for time less seconds usec timeb.h

Hello,
I try to use ftime in CVI 8.0. I get an conflict in the headerfiles between timeb.h and time.h from CVI.
It tells me that   "time.h"(61,28)   Redeclaration of 'time_t'. time.h is called in #include <ansi_c.h>.
 
The timeb.h file I get from my Visual C++.net 2003. I have set up a project in VC that runs without problems.
 
How can I avoid the conflict with the time_t declaration. 
 
Thomas

0 Kudos
Message 1 of 3
(3,977 Views)

Dear Thomas

You probably have 2 options to make that work:

 1. tweak your program using #undef such that it doesn't throw that error; this might be cumbersome, though, because I'd expect other similar errors to show up;

 2. not include ansi_c.h; this approach is much easier, because most of the ANSI-C functions can be replaced by CVI functions anyway.

Best regards

Philipp R.

 

0 Kudos
Message 2 of 3
(3,924 Views)

Is it possible to leverage timeb.h (and it's functionality) from LabWindows/CVI directly?  If not, does LabWindows/CVI support comparable functionality?

0 Kudos
Message 3 of 3
(2,848 Views)