Expert Advisors and Automated Trading - page 106

Hi, need your help on my timeccurent code in my EA, basically what I want my EA to do is only trade during specific market hours, but it just ended up not taking any trades during back testing: here's a PORTION of my code: datetime time_to_trade = TimeCurrent (); datetime open_time = "15:00:00"
The EA is optimizing OK in the MT4 version but not working in the MT5 version. This is what it is telling me. 2022.12.11 16:13:46.240 Core 04 genetic pass (0, 326) tested with error "wrong timeframe request in Open Prices mode" in 0:00:00.013 2022.12.11 16:13:46.243 MQL5 Cloud USA common
Hello, I have two questions, the first one is : I would like to create a rectangle with border color but the thing I coded didn't work. I would like a yellow border color for example. and The second question is : is there is a way to set the rectangle always on the foreground ? Because my EA draw
The first time I run the robot it throws this error but it works fine when I run it for the second time although there is no change. Why is this so? First Run: Second Run
Description: Telegram 4 MQL was made to make the life of an automtic trader a bit more convenient or better to say it was made to spare nerves. Suitable questions while operating an autotrading systems are: Was the order correctly executed?Did an situation change an unusual way so that I need to...
Do I need to submit the script file? Should I hire a freelancer to prepare the file for me? Thank you for any advice
Hey guys alittle help here , how can I make my EA read a return value from a getSignal() function in a custom indicator ?(like if getSignal function of custom indicator returns 1 when there is a signal) How can I make my EA read that to know that there is a signal created and it can execute a trade
Hello to every one I have a problem in copy trading. I bought a signal but every time MT5 open 0,01 lot for me. How can I fix that? My account: Broker: Fibo Group - Demo - Leverage: 1:400 - Balance: 3000$ Signal account: Broker: FBS - Real - Leverage: 1:500 - Balance: 16000$ would you please help me
Hello, I would like to have the open price and the current price of my open position but when I have a trade the posCurrent and posOpen are always equal to 0.0 Can you help me ? Thank you very much
I have this EA I made and I want to add a up arrow on buy signals below the candle and a down arrow on sell signals above the the candle. I'm posting the code below, Thanks in advance... //+------------------------------------------------------------------+ //|
Hi, can someone who downloaded the DEMO version of the famous <deleted> ex5 file can share it with me , because im having problem downloading it from the MQL5 market . Thank you
Hi, my code is: how please modify tp of position and keep sl as it was //+-------------------------------------------------------------------+ void ModifyTrades(){ for ( int i= PositionsTotal ()- 1 ; i>= 0 ; i--){ ulong ticket= PositionGetTicket (i); if ( PositionSelectByTicket
Hey guys need help please Is it possible to calculate the profit for the open position either buy or sell separately. I'm using AccountInfoDouble(ACCOUNT_PROFIT) to get the profit but I cannot get the profit for the buy position only or the profit for the sell position only. It gives the total
Hello, in Mql4, this code is work nice to calculate total closed profit today (current day), double Today_Closed_Profit() { int time = 0 ; int order_nya = 0 ; double Profit_History = 0 ; datetime on11 = iTime ( Symbol (), PERIOD_D1 , 0 ); // Current open time datetime on111 =
#include <Trade\Trade.mqh> CTrade m_trade; // trading object //--- ulong m_slippage= 30 ; // slippage //+------------------------------------------------------------------+ //| Expert initialization function |
I have had this code throughout my eas, scripts ands indicators but suddenly broke and returns wrong values. Then I surfed the forum, there is enough information on this but all the snippets i took also gave the same wrong answer. Is this a bug or Mql5 changed? HistorySelect ( 0 , TimeCurrent ());
I have a 3rd party EA that I use, however I have a couple of ideas for some filters to improve the EA. Not being able to edit the EA itself, I was wondering if it is able to build an EA with the add on filters, that calls the main EA if the filters conditions are met and be able to backtest the 'new
Utilizing the Sendmail function and i'm having trouble getting this right
2022.10 . 04 14 : 36 : 44.455 Tester Cloud servers switched off 2022.10 . 04 14 : 37 : 19.685 Tester F40: history check started 2022.10 . 04 14 : 37 : 30.494 Tester F40: history check timeout 2022.10 . 04 14 : 37 : 30.494 Tester F40: no history data from 2010.01 . 01 00 : 00 to 2011.01 . 01 00
Hi, when I use "every tick", "Open Prices only" and "1 min OHCL" in the strategy tester. I found that the Ask/Bid spread is not counted. Usually you use these modes for a quicker result. But when you are scalping in 1 min timeframe with 10 pips for profit. The difference is huge with or without
  Update EA  (1)
I have SignalReader-EA Telegram Copier, which is an EA that copies forex signals sent via telegram channels directly to MT4. I want to add some more signals to my EA, but I don't know how. Is there anyone here who can help me
  Candle time EA  (1)
Hello guys am just wondering how we can do time and candle condition as a basis of opening a trade example ; H1 CANDLE IS =60 MINS So i need to open trade 5 mins before current candle closes meaning i will open trade at 55 mins of the current candle close trade > close trade at 20 mins after
hi, Can I have multiple trades open per EA? My strategy that I want to consider is accumulating multiple, or aggregated, trades. I think you can only have 1 trader per Magic Number. In general, I am interested in no more 3-4 trades. Are there any example EAs where multiple trades can be opened
I am not using my EA in 100% automatic way, because I am changing direction of trades: long/short or trade disabled, but you know it's very exhausting to changing direction on 7 charts especially where is change on direction on more than 1 asset.... How to make it simplier? For example I am changing
I have a problem with a function that should set SL to 1 pip over entry price (buy mt5). In backtests it works perfect but in live trading sometimes not at all. That what it looks like in the code. // newsl double nsl= NormalizeDouble (op+ 10 * Point (), Digits ()); if (...)
Hi! I'm trying to figure out why this code only fires on one chart at 1AM, even though the EA is actually attached to multiple charts at the same time. Is my assumption wrong that globally scoped variables only apply to the chart that was attached? or are they in fact shared across charts? int
My coded mql5 when back tested works perfectly opening a trade one at a time according to my command but when I run the code on a demo live trade it opens multiple trades at a time why
Hi, I would like to be able to simulate balance withdrawal during backtesting. From the docs I see that there is a function: TesterWithdrawal() - However, as I'm testing an EA from the marketplace, I don't have access to the source code. Is there any way to simulate this without the source code
Hi, I'm testing an EA and I've added Max Drawdown Limits. However, when I run the tester, sometimes trades will at a drawdown much higher than what I've set it as. The strategy works great on demo testing over the last few months, and the Risk Limits work as intended. However I'm unable to get it
Hi, I want to know how the Print(...) function was coded, because I want to write such a function myself, which takes infinite number of parameters. Does anyone know?