Winconst tool (search Windows Constants)

The Win32 API contains many constants.
winconst.zip contains a list of more than 14000 P4GL preprocessor definitions and a utility that helps to find dependencies.
For example, the constant WVR_REDRAW is defined as (WVR_HREDRAW | WVR_VREDRAW).

When you search for WVR_REDRAW in winconst.exe it will return

&GLOBAL-DEFINE WVR_VREDRAW 512
&GLOBAL-DEFINE WVR_HREDRAW 256
&GLOBAL-DEFINE WVR_REDRAW  ({&WVR_HREDRAW} + {&WVR_VREDRAW})

winconst.zip is freeware. So feel free to download it :-)
You have to be careful when you combine constants. In 3GL programming environments you would use the OR operator to combine constants, but in Progress we only have + to work with. This can make a difference. Also, we have no unsigned long integer. As a result, some values are converted to negative signed integers. Using these values together with the + operator instead of OR may give unexpected results.

----
Jeff Pilant writes on 11 Januari 2002:

I just saw a post on peg@peg.com about this site: http:www.other-coast.com/

It pointed out how to grab constants directly from the com object file.

The page http:home.attbi.com/~marc.lafleur/Articles/ExtractingNamedConstants.html talks about a microsoft provided program to do this.

http:www.microsoft.com/com/resources/OVI386.EXE and his own program to convert this to 4GL

http:home.attbi.com/~marc.lafleur/External/typedef.zip along with samples for a number of MS products in http:home.attbi.com/~marc.lafleur/Articles/OfficeIncludes.html

Changelog for winconst.i :

26 Nov 2002: many constants for MS-Access added by Jeff Pilant

Attachments

download winconst