typedef struct tagDEC {
USHORT wReserved;
union {
struct {
char scale; // The number of decimal places for the
// number. Valid values are from 0 to 28. So
// 12.345 is represented as 12345 with a
// scale of 3.
Char sign; // 0 for positive numbers or DECIMAL_NEG for
// negative numbers. So -1 is represented as
// 1 with the DECIMAL_NEG bit set.
};
USHORT signscale;
};
ULONG Hi32; // The high 32 bits of your number
union {
struct {
#ifdef _MAC
ULONG Mid32;
ULONG Lo32;
#else
ULONG Lo32;
ULONG Mid32;
#endif
};
DWORDLONG Lo64; // The low 64 bits of your number. This is an
// _int64.
};
} DECIMAL;