Hi all My EA will not activate a buy pending order, now I'm assuming the problem might be with the Open predefined variable, if you know the problem please assist. #property strict #include <Trade\Trade.mqh> #include <Trade\SymbolInfo.mqh> #include <Trade\PositionInfo.mqh> #include
Hi Guys, wondering if is there any function to set focus on specific chart? i wrote a script to open charts with ChartOpen (MySymbol, PERIOD_D1 ); however whatever chart i run script from keep the focus not the newly opened charts, so for example if i wanted to use Comment or other functions etc on
Hello Guys, i want my ea to recognize when a new high or low has been made, i.e. higher high or lower low. I want when that happens then go short or long but i do not know how to call the last candle or how to figure out the value of the last candle so that the program knows . Thanks for your Help
Hello everyone. My EA successfully sends buy orders but for some reason cannot send sell orders. When I try to send a sell order OrderSend function fails with 4756 error code and MqlTradeResult retcode is 10004. The following is a part of my code that sends orders. void openPosition( string
Hello , thanks in advance, i don't know how to ask in the mql5 area! ok this is a MQL5 code that i write with some example and copy from a similar code i tried to build a EA that Close Partial lot in determinate price , i use this for futures markets , specifically symbol, Micro Nasdaq, this should
here is test script:
MqlTradeRequest request; MqlTradeResult result; void OnStart(){ request.action = TRADE_ACTION_DEAL; request.symbol = "AUDCAD"; request.volume = 0.01; request.type = ORDER_TYPE_BUY; request.type_filling = ORDER_FILLING_FOK;/// request...
Dear MQL5 Community, I kindly request another pair of eyes on my 4756 ordersend issue! :) Not a coder by trade, I typically work with freelancers. However with a bit of free time this summer I decided to try and work on a basic MT5 MA cross system on my own. I've gotten more or less to the "end" in
Hello, This is just to confirm I don't stuff up something before I start. I have 16 charts on a MT platform located on a VPS. I would like to turn off 4 EAs on 4 charts but keep the charts with the EA on the VPS, so option is there to turn on later. So, I just turn off the 4 EAs and then upload
Hi,I have a problem after installation of EA . I cannot trigger a trade using EA. There's a display on the Chart that shows " Turn on algorithmic trading in Expert properties". There's none in my old set-ups. Kindly see attached photo with file name 'trade problem'. There's also a different labels
Hi What indicators are importent for scalping strategy? Any usefull code example? Best regards J
I have developed an EA that I am hoping to soon use on a prop firm challenge however, I understand that live trading brings a new wave of variables to consider. The first question I would like to ask is, what else (on top of what I am about to present) should be added to a Decision Matrix to aid in
}' - unexpected end of program and '{' - unbalanced parentheses Auto-translation applied by moderator
Hi guys I'm building an MT5 EA based on a range breakout strategy i want the EA to Enter the trade at the low of the lest bullish candle before the breakout and the stoploss at the high of it like you can see on the image below Anyone know how can i do that please Thanks
Hi. I'm trying to get 2 values from a free indicator downloaded from the market. These are the indicator parameters: This is my OnInit code, that works fine because I get a message for a valid handle: int OnInit () { //--- ResetLastError (); iIndicatorhandle = iCustom ( _Symbol , _Period
Hello, I try to calculate expected profit (D) and margin requirement , but I get strange result in Tester. On Demo and Real account, it is OK. I use this code (Script) over account, and same as Expert in Tester : void OnStart () { double D= 0.01 // Volume * SymbolInfoDouble ( _Symbol
I have made a simple expert advisor with these specifications: It is based on double simple moving average cross, fast=9, slow=21. It should only enter positions on open price of new bars. To achieve this, the modeling type is "Open prices only". It uses the CTrade class to open and close positions
Hello Please could somebody tell me if it is possible to program an EA with Stop entry orders with OCO (One cancels the other)? For example, when trading Donchian channels , the EA would place Stop entry orders slightly beyond the upper and lower part of the channel and when one order is placed, the
Hi, traders and developers! I’ve wrote an EA code for a simple strategy but it has a problem related to the selected timeframe to open trades. Can someone helpme reviewing it to fix this problem? Thanks in advance. Olá, traders e programadores! Escrevi um código EA de uma estratégia simples, mas há
After running a back test (MetaTester) on a demo account, if I select the History tab in the Toolbox, I can see all the orders/deals that have been processed. My question is, is there a way to print the contents of the History tab as I am not able to
For some odd reason my script is constantly requoting buy orders but never sell orders... here is the error I get 2023.08.12 06:38:38.484 2022.10.18 07:14:54 CTrade::OrderSend: instant buy 0.01 EURCAD at 1.34759 sl: 1.34509 tp: 1.35009 [requote (1.34759/1.34809)] As you can clearly see there is
Hello. Got: 2023.08.10 14:03:02.176 Trades '3008608544': failed sell stop 10 WINQ23 at 118810 sl: 118815 tp: 118805 [Invalid expiration] I did many searches, tried many things and nothing result in success for the sell stop pending order i am trying to place. I attached the image of my broker
I know this sounds weird since we have a built in strategy tester, but what i want is to have a program that we select for example our metatrader terminal and also select the robot we want to run and to seperate backtestings, at the start of each week or each month, and at the end of backtesting to
I'm running some optimizations on the MQL5 Cloud Network and many times it only utilizes 200-500 of the thousands of available agents. Is it possible to have it utilize more agents to get the work done faster? My guess is that the network only wants to allocate 5% or so of the agents so that other
Hey all! I'm starting a personal project, a custom copier that supports MT4 to MT5 (and viceversa) communication. I'm aware that on MT4's case the common folder can be used to store and read info between terminals, howeve I couldn't find anything too helpful about communicating between MT4 and MT5
as per my search through Wikipedia, i get this answer : Algorithmic trading is a method of executing orders using automated pre-programmed trading instructions accounting for variables such as time, price, and volume. [1] This type of trading attempts to leverage the speed and computational
Hi, I limited my EA to run every minute or at the open of a new bar. I also want to do a partial close for my strategy. Because my EA only runs at least for every minute, sometimes when the volatility is high the price moves touching the partial close level and reverse at the same minute leaving the
I am using python with Mt5 and testing with Demo account This is my Close Request Data- >> Req: {'action': 1, 'symbol': 'GOLD#', 'volume': 0.24, 'type': 0, 'position': 933862679, 'price': 1919.2, 'deviation': 20, 'magic': 234000, 'comment': 'DD', 'type_time': 0, 'type_filling': 1} And this is a
I am trying to read the buffer value of an mt5 indicator , which has 4 buffers and 2 input parameters and this is how i am using it in iCustom : iCustom ( NULL , 0 , "LTD by KDMfx" ,inp1,inp2, indbuffer , candshift ); where inp1 and inp2 are the 2 input parameters of the "LTD by KDMfx" indicators
No response in Questions from Beginners thread so I'll create a new one, sorry for that! Hi. Tell me, please, how is the distance between the borders and the regression line calculated in the default Regression Channel in Metatrader ? Yeah, I know, it is said clearly in the documentation : >The
Hello all. I have 3 objects instantiated from a class in OnInit and I need to use these Objects in OnTick too, However without instantiating them again in OnTick it is not possible. I have tried passing them by reference to OnTIck and that did not work either(in this case the OnTick function does

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.