We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now


64-bit or 32-bit

mpenuel asked
Medium Priority
Last Modified: 2008-01-09
I will be distributing the .net framework 2.0 into my environment.  I have two different .exe's (one for 32-bit, one for 64-bit).  I was wondering if anyone knew of a process or registry entry or something like that I could use in my install script to determine if the machine is 32 or 64 bit.  I don't need any code (as of yet), just a way to determine if the machine is one or the other, thanks.
Watch Question

Check the Windows OS build/version number in the registry.  It will be different for 64-bit version.  If a 64-bit machine is running a 32-bit OS, you'll probably need to use the 32 bit framework anyway (which is why I recommend this check as opposed to looking at actual cpu info; I think the different versions of the framework are adjusted for the 32/64 bit API calls to the OS and not actual hardware dependencies, which makes the most sense considering that most 64 bit cpu's are backward compatible and capable of running 32 bit OS).  I don't remember the exact reg key for windows build number, but it's somewhere under HKLM/Software/Microsoft/Windows.  
Reg key should be HKLM/Software/Microsoft/Windows/CurrentVersion/ProductID - I just checked a couple versions and found it there as GUID.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts


Thanks for the repsonse, I was kind of in a hurry when try to find this, so I posted and continued research.  The key above is a good one, and I think I will use that one and HKLM\Software\WOW3264node which should also tell me if it's a 64-bit machine.

thanks again.
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.


Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.