Detect Vista 64-bit
{
if( osvi.wProductType == VER_NT_WORKSTATION )
printf ("Microsoft Windows Vista ");
else printf ("Windows Server \"Longhorn\" " );
}
It's actually fairly easy.
1. see if you are on windows vista.
2a.if your code is 64bit, just return true in your function that checks to see if its a 64 bit os. Since native 64 bit code cant run on a 32bit os, the mere fact that your 64bit code is running signifies that you on are a 64bit os.
OR
2b. If you code is 32bit, use the IsWow64Process() api. This will let you know if you are running under the wow 64 emulator( wow64 is microsfts emulator that lets 32bit apps run on native 64bit os's ). Just be carefully to dynamically load IsWow64Process or delay load it, since the api function does not exist on all versions of windows.
Hope this helps.
If i had to take a guess i would say the processor is actually a 64 bit processor. 64 bit processors can run 32 bit editions of windows vista. Im not sure how exactly you would do this via WMI on a remote computer. My previous post will only show you how to get the vista 32/64 bit version of vista on the local machine.
Hello JonnyDeep. I have a problem with my Windows Vista RC1 64-bit. Some programs are only able to run in the 32-bit version. Not even with the Program Compatibility Wizard worked. I would like to have an emulator that helps me to run these programs.
If you know of an application or a web link, please reply to my mail.
Thank You