Delphi 7 WriteProcessMemory

Posted by Tprice88 on Stack Overflow See other posts from Stack Overflow or by Tprice88
Published on 2012-03-29T16:59:40Z Indexed on 2012/03/29 17:30 UTC
Read the original article Hit count: 207

Filed under:
|

This is my Working Code

  DriftMul:=99;
  WriteProcessMemory(HandleWindow, ptr($4E709C), @DriftMul, 2, Write);

I want to Convert it without using a variable but it wont work Below is just an Example of what i want to do.

WriteProcessMemory(HandleWindow, ptr($4E709C),  ptr(99), 2, Write);

Does anyone know a way to make this work with using a variable??? I am able to program in a few languages and every language i use their is a way to to do this. The reason i want to do this is because i am gonna be making a big program that does alot of writing of different values and it will save me around 300+ lines. Below is an Example in c++ i was using.

WriteProcessMemory(hProcess, (void*)0x4E709C, (void*)(PBYTE)"\x20", 1, NULL);

© Stack Overflow or respective owner

Related posts about Windows

Related posts about delphi