Friday, July 2, 2010

Simple 64

Ever needed to determine if your .NET app was running on a 64-bit machine.  Here is a simple calculation to determine the bit type:

 if ((IntPtr.Size * 8).Equals(64)) { "this is a 64-bit machine" ; };   

I cannot take 100% credit for this as I found it somewhere else. If I find the original source, i will update the post.

[Update]  I believe this is where I found it.

No comments:

Post a Comment