Identifying the CPU architecture type using C#
问题 I want to check which CPU architecture is the user running, is it i386 or X64 or AMD64. I want to do it in C#. I know i can try WMI or Registry. Is there any other way apart from these two? My project targets .NET 2.0! 回答1: You could also try (only works if it's not manipulated): System.Environment.GetEnvironmentVariable("PROCESSOR_ARCHITECTURE") 回答2: What led me here is checking for a 32 vs 64 bit OS. the highest rated answer is looking at the setting for the Current process . After not