I've pretty much got it down how to determine operating system version, service pack level, 95/NT based, etc. for Windows XP and earlier versions by using GetVersionEx(...) and that's pretty handy for getting system information that software users probably don't know and don't know how to figure out (sadly).
A new wrench in the works is driver signing enforcement on 64 bit versions of windows (e.g. Windows Vista Home Premium 64-bit), which requires drivers to be digitally signed (read: 30 pieces of silver to MS and their cronies) which, by the way, Kaspersky and other AV folks say doesn't do squat for preventing malicious code from executing.
Driver signature enforcement may be disabled by the user at boot time using the F8 key and selecting the appropriate option, but that is inconvenient and impractical for the user. There is also a work around which can be used after the fact for this particular driver (which involves installing the signed drivers and the unsigned drivers, which are the same drivers only modified to include my PID and VID).
In any case, it would be easiest if we were able to determine the version of the operating system and resolve it down to the OS major and minor version, service pack, on which OS it is based as well as 32- vs 64-bit. Which leads to my question: How do I do that?
I think I'll need to use the GetProductInfo(...) function (?) but I'm not sure if that will do the trick or not and, further, I'm not sure how to use it and can't find any really good examples. Does anyone know if this will work and, if so, can you explain/show me how to do it? Is there another, easier, way to determine this information programatically? I'm using VC++ 6.0.