# Detect if project is running in 32 or 64 bit environment?

**URL:** https://www.finalbuilder.com/forums/t/detect-if-project-is-running-in-32-or-64-bit-environment/1705
**Category:** Discussion
**Created:** [February 18, 2011, 10:01am UTC](https://www.finalbuilder.com/forums/t/detect-if-project-is-running-in-32-or-64-bit-environment/1705 "2011-02-18T10:01:08Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [February 18, 2011, 10:01am UTC](https://www.finalbuilder.com/forums/t/detect-if-project-is-running-in-32-or-64-bit-environment/1705/1 "2011-02-18T10:01:08Z")

</div>

Other than just looking for a directory that normally only exists in x64 (like "C:\Program Files&nbsp;(x86)\"), does anyone use a reliable, elegant method to detect whether the current OS is x64 or x86?

We have developers working in a mixed O/S environment and I'm trying to find a reasonable way for them to run the same project scripts. So far, I've used kludges to do it, but this is ruffling my perfectionist feathers.

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [February 18, 2011, 11:52am UTC](https://www.finalbuilder.com/forums/t/detect-if-project-is-running-in-32-or-64-bit-environment/1705/2 "2011-02-18T11:52:58Z")

</div>

What about the PROCESSOR\_ARCHITECTURE environment variable? On 64bit it is AMD64, not sure what is is on 32, probably something like x86 (don’t have a 32bit machine at home to check).

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [February 21, 2011, 9:53am UTC](https://www.finalbuilder.com/forums/t/detect-if-project-is-running-in-32-or-64-bit-environment/1705/3 "2011-02-21T09:53:48Z")

</div>

Thanks, Vincent, good idea. On 32-bit it’s “x86”. All I need to do is check to see if that is true.
