MQL4 and MetaTrader 4 - page 708

General Exponential Moving Avg (EMA) has three Inputs 1. RPeriod 2. MA_Mode 3. Offset I would like to make "offset" that continuous change & autocalculate the value and reset its position. Offset = Verticle Price Difference between 2 price X 4
[Deleted]
  error 130.... please help  (12   1 2)
backtesting occur error 130 what's wrong with my code ?
Whenever I run a tester to test my EA (or in optimization), the tester will close all trades at the end of the period chosen (stop-out). Is there any possibility to make it such that: the period tested remains the same (from date x to date y) but, should there be open trades, the tester should, in...
Hi All, So that I can review my trades, I would like to take a screenshot of MULTIPLE timeframes for a given Symbol. I want to do this via MQL code, so the process is all automated.. Taking a single screenshot is easy, coded that and it is all working fine. However, all attempts at doing screenshots...
My martingale system doesn't work correctly.Please i need help to make it work.I won't try to explain it since it's too complicated and my eyes hurt when looking at so much variables,so i'll copy it all here and if anyone finds any errors in the code please tell me.Thanks much: SETTING VARIABLES:...
Hi everyone My problem is to close a pending order according to another opened order. For example, it is an opened order on GBPUSD and its own SL & TP, beside that there is a pending order wait to be executed by reaching to SL point of opened order. But I want the pending order to be deleted when...
Hi there, could someone please be nice to show how your code would look like, if you each new day want to open a trade end close it again lets say 4 hours later.
Hi, the 'how-to' of file open tells me: ... Handles of files opened in the same module cannot be passed to other modules (libraries) I do not exactly know what and how module is meant. I want to open a file in an include, setTrds.mqh: int iTr[ 10 ][ 50 ] ... #define Se.HDL 41 ... iTr[i][Se.HDL]
hi! i have written a custom indicator which draws some additional curves onto the main chart window. the indicator works well for a while but after some time, for example, if i come back to the chart after a few hours, i find that the indicator lines have become corrupted: they reflect the wrong...
Hi, I'm pretty advanced by now using EA, and I'm automating my trading through them, I'm working with 3 different brokers all through MT4 (Alpari, Forex.com, ActivTrades) and out of 3 months of trading, this has happened once on each one. I request to open an order, and receive the ticket I...
[Deleted]
Hi! I want to write a function that will allow me to enter at least 3 dates with times as external variables, so that during those times (or for example for two hours after those times) my expert advisor would not make any trades.Can you please point me to the right material where I can learn how to...
[Deleted]
I have an EA which opens 2 orders of differing lot size. Occasionally, 1 lot will not open, or I will close one lot manually, etc. I'd like to be able to display the open order status on the chart, rather than searching through the terminal to find the pair, etc - can this be done automatically?
[Deleted]
Everyone, I have developed a relatively simple EA, and wanted to test it by using Strategy Tester in order to find the best setup (S/L,T/P). I recognized that the numbers in the report after several runs are different. So I decided to run the EA on Strategy tester 3 times in a row, without changing...
I have written an EA that has to scan multiple currencies and give an alert when certain conditions are true for a particular currency pair. Can I test this EA in the Strategy Tester and receive Alerts when a condition is met in a particular currency?
I wanted to test signal for a broker but it doesn't work because symbols are suffixed with m by broker so expert cannot recognize. Is it possible to change ?
It took me months to getting started I have given up multiple times this is why : there are tons of very good but lengthly articles as well as samples codes without explanation so when a beginner who tries to understand and not just copy and paste - often it doesn't work - you have to extract the
When running logic every tick - only looking at open trades and staying away from history trades - the backtesting suffers and takes longer. If you move that logic to a DLL (probably c# or freepascal or c++ sample in mt4passing either each tick or an array[] - something efficient ) - well ............
string look1, look2, symarray[ 5 ]; symarray[ 5 ] = { "EURUSD" , "EURJPY" , "GBPUSD" , "USDCHF" , "JPYGBP" }; ArraySetAsSeries (symarray, false ); // index starting 0 at left look1=symarray[ 0 ]; look2=symarray[ 1 ]; Print ( "symarray 2 elements 0 = " +look1+ " and 1= " +look2); Simple eh! except
[Deleted]
Hello, Is it possible to move the time backwards by some increment (eg tick, candle, etc.) in the Strategy Tester? Or to start the tester at a specific time of day? Thanks.
[Deleted]
Hi, can someone tell me if it is possible to download the entire archive of EA's from code-base in one go ? For example from an ftp folder. Regards Rob
HI, I want to be able place 9 currency pair rates inside array specified to that pair. Compiles successfully without errors, so there is no syntax errors in the code. But In Terminal when I am launching EA in message window, it shows this kind off error: 2013.08.08 21:22:47     multi_chart GBPUSD...
Hi there, I am pretty new to MetaTrader 4 and are about to program a simply entry order. But everytime I compile I get these errors: '{' - expression on global scope not allowed '\end_of_program' no function defined my code is: {   int ticket;   double Start_time = 0.00;      if( TimeCurrent() ==...
I have a script to export quotes but it only works if I open a chart. Can't I modify so that I'm not obliged to open a chart first ? Excerpt of source code : FileWrite (handle, "Time;Open;High;Low;Close;Volume" ); // data recording for ( int i=iBars(symbol,theperiod); i>= 0 ; i--) { datetime t =
hi everyone please share customized alarm for (QQE ADV) indicator in MT4 when RSI line crossed signal line and 50 line at same direct (buy or sell) thanks alot.
In Expert window I only get "Print Tick EURUSD,M1: loaded successfully" nothing more whereas I did ask to print every tick. There's no error. I have no indicator in chart just this expert, no other charts open. int start()  {                           int i;                  string symbol;...
I have written some basic code to incorporate into my EA, where by, if the server time is out of my trading time frame, no trades will searched for, let alone any positions be placed. I have a few questions around this: 1) Can this be properly analysed via Strategy Tester, or is that impossible...
I created this EA using Expert Advisor Builder (http://sufx.core.t3-ism.net/ExpertAdvisorBuilder/index.html). This EA uses parts of the GMMA indicator. It just utilizes 7 of the 12 moving averages for simplicity. It opens one position when conditions are met and Trailing Stops takes care of the...
I have the latest update to MT4. My broker is IBFX and they are useless in helping me. I have windows 8. After the last update, when I completely close MT4 I lose all my settings. What I mean is when I open MT$ from being closed down I have to click on "view" and toolbars and get all my toolbars...
After having been at Forex for awhile now, both coding and trading, I'm beginning to suspect that retail traders have almost no chance of being profitable consistently. Even when you find an EA that has perfect backtest results you find something like it utilizes no stoploss. Even a pure...
In my expert start() I have          handle = FileOpen(filename, FILE_CSV|FILE_WRITE, ";");                  if(handle > 0)         {            FileSeek(handle, 0, SEEK_END);            FileWrite(handle, quote);            FileClose(handle);         }   But I got only one line in my file...