Reply To: Is there a way to determine what OS MEW 9.10 is running on?

Product Compare Forums Multi-Edit Support Is there a way to determine what OS MEW 9.10 is running on? Reply To: Is there a way to determine what OS MEW 9.10 is running on?

#6022
Ernie Zapata
Participant

Ok .. I don’t believe there is a pre-existing macro definition (#define) that tells the compiler under what OS it is executing, at least nothing documented and nothing that I can see in the macro source files.

You could always create a .sh file, say something like WinVersion.sh and on Win95 installations, have something like:

#define _Win95 1
#define _Win2000 0

and on Windows 2000 installations, have WinVersion.sh consist of:

#define _Win95 0
#define _Win2000 1

And in your macro source, do a

#include WinVersion.sh

and in your code, have something like:

#if _Win95
#endif

#if _Win2000
#endif

There is also a command line option of CMACWIN to define macros.