x64

Is Process 64bit

March 3, 2020
Delphi, x86, Detect process architecture, x64

Tiny snippet to know whether or not target process id is running under 32bit or 64bit architecture. If result is True, target process is running under 64bit architecture. If result is False, target process is running under 32bit architecture. // // Jean-Pierre LESUEUR @DarkCoderSc // // ... uses Windows, SysUtils; // ... type TArchitecture = (x86, x64, xUnknown); // ... function IsProcessX64(AProcessId : Cardinal) : TArchitecture; var AProcHandle : THandle; AWow64Process : bool; begin result := xUnknown; /// { If we are not in a 64Bit system then we are for sure in a 32Bit system } if (TOSVersion. ...