Expert Advisors and Automated Trading - page 216

I understand that the demo account broker sets the commissions so that when you backtest they are locked in. Is there a way get around this? Are there any brokers that allow you to set zero commission for a backtest? Thanks
I made my own indicator that has a separate window where it shows buttons. Alone it works like it should. When i import it with the iCutsom function , the indicator doesn't get shown at all and also the Buffer Values stay empty. What can i do to make it work? int Gui; int OnInit () { Gui =
Hi, Some of the EAs that is on the market can be activated on a demo account, some of them can't. I have published som EAs on the market and I want to know how to get it to run on a demo account. I have searched a lot but I cant find the solution. Does anyone know and could share it with me? Best
This code of mine was not counting only buy positions it count also sell position but I want it to count it separately to have a value of how many buy and sell position I have. Please help me find the problem. #include <Trade\Trade.mqh> CTrade trade; void OnTick () { Comment ( "BUY = "
I have an issue, where after adding custom symbol with daily data the expert advisors have trouble with proper testing. After the testing is finished, the result is 0 or close to 0 profit . Tried with different EA and on other built in symbols so assume, there is a problem with the custom symbol
Simpe SellLimit script dont work - EURUSD Work fine in Advisor. But dont work in Script. #include <Trade\Trade.mqh> CTrade m_trade; void OnStart () { MqlRates rates_old[]; ArraySetAsSeries (rates_old, true ); int bars = CopyRates ( Symbol (), PERIOD_D1 , 0 , 10 , rates_old);
Hi, I searched the forum but I couldn't find anything about it. When multiple orders of an MT4 or MT5 EA have the same TP, the ticket numbers overlap making them illegible and therefore useless. I'd like to delete or hide this number or better still customize the text and color as per the attached
I am having an issue which I suppose should be extremely simple but I cannot solve it. Here is my EA: int counter = 1; OnTick(){ do stuff with counter; } My problem is, every time I launch another EA on a different pair, it changes my counter back to 1 in every EA. Obviously I know this is because
  CopyBuffer Limitation!  (12   1 2)
hi guys i tried to make system to back test my theory however when i try CoppyBuffer seems Maximum number it work is 35 ! so wondering if there is any workaround this limitation?! since i want whole year buffer eb examined oh btw its not for iCustom just official indicators buffered tnX for help in
Hi, I created a EA using Expert Advisor (generate), when i use backtest everything works fine, tp and sl works perfectly, but when i use the EA in the real market everything stops working. The EA opens a position and adds tp and sl but before the trade ends it starts another one but this time it...
Hi I have an EA which i gather information I need (Bar information and iMACD for example) and send it back to python for calculation and as what to do. I want to add a function that when I star EA, sync the data with python. here I explain more: python send the date and time of the last bar that has
Hi, New here, so please forgive the usual lack of understanding! I want to put a trailing stop loss on a trade, that only kicks if the trade moves a certain distance from the entry point. I've been trying to research EA's all day, but with no coding knowledge its baffling me. It doesnt seem like
Hello, I'm using an Sqlite database to do some documentations. It works perfect when making a single test. But during optimization the database access (= create some records) only works in the "OnTesterDeinit()" event. I tried to access a Sqlite Database during optimization in the OnTick event. But
I need a EMA crossover EA which will work on Multi time frame. Can anyone help ? Thanks :-)
Hello Guys, I attached an image where an order is placed with Price: 94460, Stop loss: 93960 and Take: 94560. But the transaction was closed with only 10 pts, at 94470. What I can do in my code to prevent this? Best Regards, Logs: 2020.10.06 23:47:32.962 2020.10.05 11:17:16 instant buy 1 WIN$D at
Good evening, I would like to use this open source ea for personal use but I realized that it does not have the comment function at the opening of orders, so it does not track us and you could get confused with other manually opened positions. it's possible? Can anyone help me? Thank you
About 60% down on this page describes the [tester] parameters that one would put into a configuration file to run a strategy test from the command line. https://www.metatrader5.com/en/terminal/help/start_advanced/start As examples: Model — tick generation mode (0 — "Every tick", 1 — "1 minute OHLC",...
  Modify SL AND TP  (3)
I dont know how can i modify my SL and TP. I've tried allmost everything. I just can't change it to TP=50 and SL=20 pips. Anyone can help me? //+------------------------------------------------------------------+//|                                                EMA EMA STOCH.mq5...
hi! can anybody help me build an ea that opens a buy and sell order every candle closed within a specific timeframe
Hi everyone, I'm on my first EA (with mql5) and I have some trouble. My goal: Get new datas from Calendar event after maximum 5sec. Unforthunetly I get new data sometimes after 1 minutes, sometimes 4 minutes.. It's too long ! I don't understand why, I use EventTimer() to launch the trigger who check
I wonder how to make an EA that is triggered by two indicators ( leading / lagging ) .. I mean that their signals does not appear on the same bar ?! For Example : if I am using a stochastic cross as a primary signal and I want the EA not to start the buy or sell order till it gets a confirmation
hello guys, im new here and i already tried hard to find out want i want buy still cannot find it yet i really need help to find this EA or can some one create this EA  Can anyone help me please? I want EA that can auto modify TP/SL both Buy/SELL Oders to xxx pips or xxx prize base on break...
Could anyone make a very simple EA with a button? With this EA I'll press buttons the whole day to see if I'm good at it. EA should have: - If I press the sell button, then EA should open sell 1 lot + at the same time buy 0.9 lot, 10tp/sl - add same button, but for buy - add sell button with tp/sl...
input int volume, rsiP, bandP;input double sl, bandD;input ENUM_TIMEFRAMES tf;input ENUM_APPLIED_PRICE bandAP;bool ok = false, closing = false;//+---------------------START TIME CLASS-----------------------+datetime cStartTime(int pstartHour= 0, int pstartMinute= 0){MqlDateTime...
Hi ! Can someone help my EA, i need it to open a position when the K and D lines are crossing above 20 and then close that same position when it crosses down 81, that is for the bullish positions. I also need it to open another position when the stochastic crosses down 80 and then close the position
Tried setting up multiple currency pairs for trading from within in the expert for the first time. Everything seemed fine, with trades from every pair showing up in the backtest report on MT5. However, just for the hell of it I tried changing the pair on the settings panel in MT5. I assumed this
[Deleted]
Can We define functions that like  Print("Hello","World"," !"); http://www.equestionanswers.com/c/variadic-function.php Can I define these fuctions in mql4 or mql5?
Hello, I am currently looking for the reason of a repaint issue that only occurs in the MT5 backtest. The following question: I do a backtest in the M5 period, modeling "Every tick based on real ticks". My EA fetches the data of the last D1 candle for every new M5 candle. Does this D1-data
I have this code: double previousBar_open = ( double ) iOpen ( _Symbol , PERIOD_CURRENT , 1 ); double previousBar_close = ( double ) iClose ( _Symbol , PERIOD_CURRENT , 1 ); double previousBarDifference = NormalizeDouble (previousBar_close - previousBar_open, _Digits ); Print
(see attached file) i can't figure out why this ea doesn't show the buttons in a new window. When i start it on a window literally nothing happens. Any help would be appreciated! //+------------------------------------------------------------------+ //|