Hello. I've just downloaded black magic and i am trying to read window calculator's window title (that is on my computer called "Calculadora").
so, from what i've understood,
Code:
string pattern = "43 61 6C 63 75 6C 61 64 6F 72 61"; //"Calculadora" in hex
string mask = "xxxxxxxxxx"; // 11 x's -> as many as there are chars in "Calculadora"
BlackMagic memread = new BlackMagic();
if (memread.OpenProcessAndThread(SProcess.GetProcessFromProcessName("calc")))
{
uint dwCodeLoc = memread.FindPattern(pattern, mask);
Console.WriteLine(dwCodeLoc);
Console.WriteLine(memread.ReadUnicodeString(dwCodeLoc, 40));
so what I get is always something like "MZ". I've tried ReadASCIIString too and the same thing happens(though the text is kinda dif, but trash the same way). This must be really simple, what might I be doing wrong?
Thanks!