Forum

A question of style?... properties files and refactoring....

Hi this is a general question about project patterns in MQL4. I got my first decent EA working. In the interest of expediency i stuck all logic in one ea file first. I then refactored it to be a bit more OO and created some classes but everything remained in the one file. Before I develop further

clean up my objects

Hi , apologies for the basic qn but I'm used to teh JVM doing this magic for me. I have a function that is called OnTick, it creates a few object instances, makes calculations and passes on the object reference to a controller function, controller does his thing and exits/finished. simplified code

Accurate Backtesting -- Different timeframes.

I am writing my first EA (again!). I am trying to simulate an existing MT4 indicator so I can confirm my calculations are correct. So I am trying to calculate the ichi-moku calculations for Hourly and Daily in one EA and compare my results to the packaged MT4 one. My issue issue is, when running my

Object Oriented

Hi, I come from Java background so apologies if this question is obvious to c/c++ peeps. I have two objects BaseObject and SecondObject . SecondObject is initialised with a parametrised constructor containing BaseObject or in this world a pointer/reference not the object itself like i do in java

First EA- Simple example --phase 1

Hi, I'm about to write my first EA and I was hoping for guidance and perhaps someone could point me towards a similar simple example. I hope to write a simple EA that just calculates and prints values for now and then build on it. As a training project I'm going to use Ichimoku... Phase 1. Simple

Historical Data - Model Quality

Hi, how do I improve the quality of the historical data for strategy tester . I have downloaded all available data in the History Centre, currently trying to test GBPUSD on my MT4, Interbank FX platform but when i run my script the model quality is listed as 25%. Is there a better data source I can

check if pending order has opened

Hi, How can i check if a pending order has been triggered? I have two pending orders and want to cancel one if the other opens but can't see a method to check if the order has been triggered? Thanks, Tori

Count Candles

Hi all, Would anyone know of/have an indicator that counts and displays the number of candles since a candle hit/left a moving average ? For example it would start counting candles as soon as a candle has moved, say 30 or 50 pips (or any similar small figure) from a moving average (that could be

Time since candles at a moving average

Hi, does anyone know of / have an expert indictaor that will let me know (thru any visual means) when candles have been away from a moving average for a certain time. e.g if i set the time to be 200 candles and the moving average to be the 200 SMA as soon as the chat indicates that it has been 200