Get data from a metatrader 4 alert
Get data from a metatrader 4 alert
Loading saved threads...
alfredo alonso · External communityPost link
External question — Stack Overflow Stack Exchange
Author: alfredo alonso
Original post: https://stackoverflow.com/questions/67024604
License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/
Adaptation: HTML converted to plain text; contact email addresses removed.
I use an indicator that generates alerts like: eur / USD Buy 1.122323, TP 1.131232, SL 1.114354, my question is how in an EA to read this data to execute the buy order.
Quote
Report
Yasin İPEK · External communityPost link
External answer — Stack Overflow Stack Exchange
Author: Yasin İPEK
Original post: https://stackoverflow.com/a/67836969
License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/
Adaptation: HTML converted to plain text; contact email addresses removed.
cheat engine memory
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using Telegram.Bot;
namespace ConsoleApp45
{
class Program
{
const int PROCESS_WM_READ = 0x0010;
[DllImport("kernel32.dll")]
public static extern IntPtr OpenProcess(int dwDesiredAccess, bool bInheritHandle, int dwProcessId);
[DllImport("kernel32.dll")]
public static extern bool ReadProcessMemory(int hProcess,
int lpBaseAddress, byte[] lpBuffer, int dwSize, ref int lpNumberOfBytesRead);
public static void Main()
{
string ipek = "";
for (int i = 0; i < 10; i++)
{
Process process = Process.GetProcessesByName("terminal")[0];
IntPtr processHandle = OpenProcess(PROCESS_WM_READ, false, process.Id);
int bytesRead = 0;
byte[] buffer = new byte[10];
//02DD12A4 cheat engine den alınan değer 0x02DD12A4 bu şekilde girilir.
ReadProcessMemory((int)processHandle, 0x02DD12A4, buffer, buffer.Length, ref bytesRead);
string yasin = Encoding.UTF8.GetString(buffer);
}
}
}
}
Quote
Report
Post Reply
Quoted from Forex.com.bd-Editorial External question — Stack Overflow Stack Exchange Author: alfredo alonso Source score (net votes, not local likes): 0 Original post: https://stackoverflow.com/questions/67024604 License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/ Adaptation: HTML converted to plain text; contact email addresses removed. I use an indicator that generates alerts like: eur / USD Buy 1.122323, TP 1.131232, SL 1.114354, my question is how in an EA to read this data to execute the buy order.
Checking account access…