Şartname

I've been studying the possibility of developing an EA that connects to other mt5 accounts and "sends" orders from the master account using the login details of the slave accounts, I wrote the code below but I can't compile it and I don't know if it makes sense.


I'm looking for someone to adjust this code and compile this EA


//+------------------------------------------------------------------+
//| Global variables declaration                                      |
//+------------------------------------------------------------------+
input string otherAccountLogin = "";    // Login of the other account
input string otherAccountPassword = ""; // Password of the other account
input string otherAccountServer = "";   // Server of the other account
int otherAccount = 0;                   // Account number of the other account

//+------------------------------------------------------------------+
//| Expert Advisor initialization function                           |
//+------------------------------------------------------------------+
int OnInit()
{
   // Connect to the other account using the provided login, password and server
   otherAccount = AccountOpen(otherAccountLogin, otherAccountPassword, otherAccountServer);
   if(otherAccount == 0)
   {
      Print("Failed to connect to the other account");
      return INIT_FAILED;
   }

   return INIT_SUCCEEDED;
}

//+------------------------------------------------------------------+
//| Expert Advisor tick function                                     |
//+------------------------------------------------------------------+
void OnTick()
{
   // Get the latest trade from the current account
   MqlTradeRequest request;
   MqlTradeResult result;
   if(!AccountTradeLast(request, result))
   {
      Print("Failed to get the latest trade from the current account");
      return;
   }

   // Execute the trade in the other account
   if(!OrderSend(otherAccount, request, result))
   {
      Print("Failed to execute the trade in the other account");
      return;
   }

   Print("Trade replicated in the other account: ", request.symbol, " ", request.action, " ", request.volume);
}


Yanıtlandı

1
Geliştirici 1
Derecelendirme
(186)
Projeler
205
26%
Arabuluculuk
12
25% / 58%
Süresi dolmuş
39
19%
Serbest
2
Geliştirici 2
Derecelendirme
(12)
Projeler
16
0%
Arabuluculuk
0
Süresi dolmuş
2
13%
Serbest
3
Geliştirici 3
Derecelendirme
(6)
Projeler
8
0%
Arabuluculuk
8
13% / 88%
Süresi dolmuş
0
Serbest
4
Geliştirici 4
Derecelendirme
(624)
Projeler
701
42%
Arabuluculuk
2
100% / 0%
Süresi dolmuş
1
0%
Serbest
Yayınlandı: 9 kod
5
Geliştirici 5
Derecelendirme
(298)
Projeler
478
40%
Arabuluculuk
105
40% / 24%
Süresi dolmuş
82
17%
Yüklendi
Yayınlandı: 2 kod
6
Geliştirici 6
Derecelendirme
(11)
Projeler
17
59%
Arabuluculuk
2
0% / 100%
Süresi dolmuş
2
12%
Serbest
Benzer siparişler
Consulta a programador experiente em B3 — divergência entre ambiente de teste e execução real Estou procurando a opinião de um programador com experiência específica em MT5, execução na B3 e mercado de futuros brasileiro , porque estou investigando uma questão de comportamento de um Expert Advisor. Tenho um EA desenvolvido para operar mini índice , e nos testes realizados no Strategy Tester do MT5 e também em conta
Preciso de um EA consistente no mercado forex, Pode ser EA de GRID, Scalping, que eu possa escolher até quantas ordens deve abrir, qual o volume do lote, horários para abrir novas ordens, que faça o cálculo das ordens abertas e se estiver no lucro que eu escolher no painel, assim ele fechará, mesmo que eu tenha parado as ordens naquele certo horário. O Setup será básico, de Médias Móveis, Estocástico
------------------------------ ## 💻 Código-Fonte MQL5 Atualizado com Trava de Tempo: O Libertário (v5.6) Aqui está o código completo e finalizado com todas as suas exigências inseridas e estruturadas em grupos de inputs organizados para o MetaTrader 5: //+------------------------------------------------------------------+ //| O_Libertario.mq5 | //| Keltner Pullback + RSI + Opções de
Preciso de um EA consistente no mercado forex, Pode ser EA de GRID, Scalping, que eu possa escolher até quantas ordens deve abrir, qual o volume do lote, horários para abrir novas ordens, que faça o cálculo das ordens abertas e se estiver no lucro que eu escolher no painel, assim ele fechará, mesmo que eu tenha parado as ordens naquele certo horário. O Setup será básico, de Médias Móveis, Estocástico

Proje bilgisi

Bütçe
30 - 500 USD
Son teslim tarihi
from 1 to 10 gün