For some reason it doesnt update my trades with the new TP. Please help. double BAvgTP (){ double ask = NormalizeDouble ( SymbolInfoDouble ( _Symbol , SYMBOL_ASK ), _Digits ); double newbtp; double loss = 0.00 ; double Lsize = 0.00 ; for ( int i= PositionsTotal ()- 1 ;i>= 0 ;i--){
Hello i have ((account balance )) in my EA panel,But when open position the balance it does not really move with the balance unless I make an refresh manual,How do I make it move every tick with balance in the include file please. m_lMainAcc.Create( NULL , "lMainAcc" , 0 , 20 , 40 , 1 , 1 );
Hello i am experiencing a serious problem during automatic product validation testing, the robot is based on the US30_Spot and when running it in strategy tester , real account, demo account, no errors appear at all, not even warning and everything is operating perfectly when uploading the file and
Hi, I want to ask about selecting position by ticket function. My EA is multi-currency EA and I store each buy ticket and sell ticket to BuyTicket[] and SellTicket[] Array. Usually when I want to select a position I will use loop through all open position and select each position by the ticket then
Hi, Very odd anomaly is happening. In my backtest the EA trades as programmed, one trade per day, but sometimes it places two trades in live with in one second time difference and open price is only few pipettes apart. When I backtest the exact date of the duplicate trades, then it places a single
I always look at the chart and wait for the price to hit my target to place a market order. This is because my limit orders often don't get triggered due to the spreads. Is there a script to place a limit order as if it was a market order
Hello everybody. I would like to know if there is a way to access the entire trading history through the OrdersHistoryTotal() function. If so, how can I do this via code? Thank you in advance for everyone's help and understanding
Hi guys, I am very new to this platform so please bare with me... I have recently started building an ea using mql5. I have coded it in such a way that if the previous DEAL_ENTRY_OUT returns a negative profit value, the buy/sell will not be executed until a new bar has been printed. As part of the
Hey, i have strange issue, when my tp is rising, acc equity also Then when tp is reached im closing positions (both types, BUY and SELL) And now when positions are closed, total profit is decreased as on attached pict: so i know it is tester and generally logic should be ok, but i dont want to show
[Deleted]
Good day, I am experiencing an issue with the stability of my EA/ EA's. It appears to become Unresponsive after X amount of time being attached to the chart. By unresponsive I mean that the EA has been left to run on its own, without interference, and after X amount of hours I am still connected to
I am trying to print the history symbols are type along with date however the results are completely messed up time of deals are not matching the history ,tickets, type of buy and sell are not matching (i assume it return 1 for buy and 0 for sell) can anyone check my code and tell me what am i doing
Hello, I am trying to implement the main prop firm rules within my EA: - stop trading when 8% profit reached - stop trading when 10% loss reached - stop trading for the day when 5% drop from the equity at the opening of the day. I have the following code to save the equity at the opening of the day
//--- Include standard libraries #include <Trade\AccountInfo.mqh> #include <Trade\PositionInfo.mqh> #include <Trade\SymbolInfo.mqh> #include <Trade\Trade.mqh> //--- Classes CAccountInfo AccountInfo; CPositionInfo PositionInfo; CSymbolInfo SymbolInfo; CTrade Trade_A; input uint
Hello, I am new to programming and wanted an answer to my following question. In mql5 the instructions in the Ontick function are executed at each Tick. is there a way to take the price value (bid or ask) at a given time and store it as a reference value to use it later in the program. for example
For an MT5 demo account on [Redacted] I try to use mql5 to retrieve the account number using " AccountInfoInteger(ACCOUNT_LOGIN)" and as can be seen form the attached screenshot instead of getting my account number 3000051923, I am fed back with a negative number that does not look like any account
Hi, When using the strategy tester for optimisation, is it possible to ignore certain combinations? For instance, if I optimise the below parameters (example), the tester will test all combinations even if the first parameter is false: For example: Ideally, I only want combinations of Bollinger
Hello everybody. I developed the code below to return last month's profits. For some reason beyond my knowledge, the returned value is different from the MT5 one. Could someone tell me where I'm going wrong? //--- double GetProfit() { double profit = 0 ; //--- int timeDay = 24 * 60 * 60
Hi all, I am trying to partially close my position once a certain risk reward is reached. Both proportion of the position to be close, and the risk reward needed to be reached are inputs. I am struggling regarding the volume, as I want the partial cloture to happen only once, so when the volume of
Hi all, I am trying to test an EA on different timeframes and so I defined timeframe as an input. The code is working fine when tested on a single timeframe. To have the timeframe changed, I simply added the following 2 lines of code. The first one is in the global scope and second one is in the
Hello, Just to clarify, I monitor my VPS EAs via the platforms on my Desktop. When I am required to have a Windows Update sometimes the Platform is updated also, which is not new to anybody. On my Desktop and when I have a Platform Update there are changes within my EA which tells me via the
Hi! I'm operating an strategy that opens BUY-LIMIT or BUY- STOP orders . Due to my EA limits, I need to get the information about when these orders are effected and I tried the following code: if ( HistoryDealSelect (trans.deal)) { deal_ticket =
Hi, I started trying to make EAs for the first time just by going through MQL5 articles like this one: https://www.mql5.com/en/articles/367 This talked about making a signal script (.mqh) for the EA wizard. They inherit the CExpertSignal baseclass and then override the LongCondition and
Hi all, is there the possiblity to distinguish the buy arrow color that opens a new position (or pending order) from the the buy arrow color that closes as sell position? Thank you
[Deleted]
I tested my EA at a friends pc and the global variables show up fine.
But at my PC it only returns 0. same ea. same set. same time.
Also they shop up at my pc in demo or real mode. they only dont show up in strategy tester mode
anyone has an idea?
Hello, Please who can help with BOOM and CRASH expert advisor or where to get it? Regards
Hi all, in an expert I modified an input variable as follow (from false to true) Then I compiled the expert as usual. When I lauch the strategy tester in the journal tab I still see the variable as false. Where could be my mistake? Thank you
Hello, For some time now, I've been using an EA with a trusted broker, and it's been working without any issues. Recently, I opened an account with a new broker, and today the EA was running on both accounts. On the previous broker's account, it opened a position, but on the new broker's account, an
My old EA is being executed even when the autotrader button is in "OFF" mode. This is a problem because I dont want to execute trades during certain times of the day and I am using also using a new EA. Therefore, the old EA is no longer needed. Is there any way I can delete any history of the old EA
hi can any one help me i don't what can i do to fix this i already test the expert
What's wrong with this: string LogPrint= StringConcatenate("Start Equity is ",DoubleToString(StartEquity,0),", Account Equity is ", DoubleToString(AccountEquity(),0)),". Re-starting"); Why do I get these 2 error messages? "'Start Equity is ' - variable expected HMDemo.mq5 122 49" and "
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
If you do not have an account, please register
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.