LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Accessing Windows 2000 features

I tried to use the Windows 2000 feature EWX_FORCEIFHUNG (function ExitWindowsEx).
The compiler makes an error: unknown value.
I check the Winuser.h and I change the define WINVER to 0x0500. Then the compiler makes 10 warnings (created by NI) but still the error: unknown value.
I do not think I have to change the SDK include files so I guess my way is not the good one.
Thanks for help.
0 Kudos
Message 1 of 2
(2,784 Views)
In the SDK help files, it gives the following info...

The following table indicates the macros you must define to target each system using the SDK headers.

Minimum System Required Macros to Define
Windows 95 and Windows NT 4.0 WINVER=0x0400
Windows 98 and Windows NT 4.0 _WIN32_WINDOWS=0x0410 and WINVER=0x0400
Windows NT 4.0 _WIN32_WINNT=0x0400 and WINVER=0x0400
Windows 98 and Windows 2000 WINVER=0x0500
Windows 2000 _WIN32_WINNT=0x0500 and WINVER=0x0500
Internet Explorer 3.0 _WIN32_IE=0x0300
Internet Explorer 4.0 _WIN32_IE=0x0400
Internet Explorer 5.0 _WIN32_IE=0x0500

I tried using the example you show, and I too got an 'unidentified identifier' error... if you put an

#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0500
#endif

it works
fine...
Message 2 of 2
(2,784 Views)