ReadProcessMemory(): byte[] buffer = new byte[] { }; ==> byte[] buffer = new byte[bytesToRead]; (the lack of capacity was causing errors to be thrown)