Getting OS name in VC++

rag84dec's Avatar, Join Date: Jul 2007
Go4Expert Member
HI all,

There is one problem with VC++.The minor number and major number for "Vista" and "Windows 2008 server" are same.So, in order to distinguish between the two wProductType should be used.But winbase.h packaged with vc++ 6.0, wProductType field is not available.

My question is ... Is there any other way of getting the Proper OS name ?.

Thanks in advance...
0
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
Check out OS version detection for 32 and 64 bit OS.
0
rag84dec's Avatar, Join Date: Jul 2007
Go4Expert Member
This is what i have done. But your code does not mention how i will differentiate between Vista and Wind 2008 server through some other method . since productid is not supported in the OSVERSIONINFOEX.
0
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
Quote:
Originally Posted by rag84dec View Post
This is what i have done. But your code does not mention how i will differentiate between Vista and Wind 2008 server through some other method . since productid is not supported in the OSVERSIONINFOEX.
Probably because when I wrote I did not had that OS and so table probably needs upgrade.