C# Program to Check Whether Running Process is 64-bit Process or Not Using Environment Class Last Updated : 01 Nov, 2021 Summarize Comments Improve Suggest changes Share Like Article Like Report Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that retrieves command-line arguments information, exit codes information, environment variable settings information, contents of the call stack information, and time since last system boot in milliseconds information. In this article, we can check which process is running in our system using the Is64BitProcess property of the Environment Class. This method is used to check whether the current process is the 64-bit process or not. If the current process is a 64-bit process then it will return true otherwise it will return false. Syntax: Environment.Is64BitProcess Return Type: The return type of this property is boolean. It will return true if the process is a 64-bit process. Otherwise, return false. Example 1: In this example, we are running our code on a 64-bit machine. C# // C# program to determine whether the given // process is 64-bit process or not. Using // Is64BitProcess process of Environment Class using System; class GFG{ static public void Main() { // Declare a boolean variable and set to false bool process = false; // Set the method to the initialized variable process = Environment.Is64BitProcess; // Check whether the current process // is 64-bit process or not if (process == true) Console.WriteLine("The current process is 64-bit process"); else Console.WriteLine("The current process is not 64-bit process"); } } Output: The current process is 64-bit process Example 2: In this example, we are running the same code on a 32-bit machine and we get a different output because now the process is 32-bit. C# // C# program to determine whether the given // process is 64-bit process or not. Using // Is64BitProcess process of Environment Class using System; class GFG{ static public void Main() { // Declare a boolean variable and set to false bool process = false; // Set the method to the initialized variable process = Environment.Is64BitProcess; // Check whether the current process // is 64-bit process or not if (process == true) Console.WriteLine("The current process is 64-bit process"); else Console.WriteLine("The current process is not 64-bit process"); } } Output: The current process is not 64-bit process Comment More infoAdvertise with us Next Article C# Program to Check if Operating System is 64-bit OS or Not Using Environment Class S sravankumar_171fa07058 Follow Improve Article Tags : C# CSharp-programs Similar Reads C# Program to Check Whether a Process is Running in User Interactive Mode or Not Using Environment Class In C#, Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that it retrieves command-line arguments information, exit codes information, 2 min read C# Program to Check if Operating System is 64-bit OS or Not Using Environment Class Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that retrieves command-line arguments information, exit codes information, environme 2 min read C# Program to Check Whether the CLR is Shutting Down or Not Using Environment Class In C#, Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that it retrieves command-line arguments information, exit codes information, 2 min read C# Program to Get the Memory Size For OS Page File using Environment Class Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that retrieves command-line arguments information, exit codes information, environme 2 min read C# Program to Get Number of Processors of Current Machine using Environment Class Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that retrieves command-line arguments information, exit codes information, environme 1 min read C# Program to Get the Environment Variables Using Environment Class In C#, Environment Class provides information about the current platform and manipulates, the current platform. It is useful for getting and setting various operating system-related information. We can use it in such a way that it retrieves command-line arguments information, exit codes information, 3 min read Like