private ReadProcessMemory ( |
||
process | ||
address | ||
buffer | byte | |
size | uint | |
read | uint | |
Résultat | bool |
/// <summary> /// Reads memory at the address /// </summary> /// <param name="address">Memory address</param> /// <param name="buffer">Buffer</param> /// <param name="size">Size in bytes</param> public void ReadMemory(IntPtr address, byte[] buffer, int size) { if (isDisposed) { throw new ObjectDisposedException("Memory"); } if (buffer == null) { throw new ArgumentNullException("buffer"); } if (size <= 0) { throw new ArgumentException("Size must be greater than zero"); } if (address == IntPtr.Zero) { throw new ArgumentException("Invalid address"); } uint read = 0; Win32.ReadProcessMemory(processHandle, address, buffer, (uint)size, ref read); }