MQL4 and MetaTrader 4 - page 689

[Deleted]
  2 Loops into each other  (16   1 2)
Morning, i want to use a loop with different 2 variables. How does this work? for (int j; j >= 1 ; j--) && (int i; i >=1 ; i)    {    Formula[j,i] = (3*j+i*2)    }
Hello everyone,  I have seen a few threads where the code for once per bar trading is explained, but I am really new to programming so I can't fix it myself :/  Also, if someone could help me out with inputting a part of code for the size of a bar I would appreciate it as well, for example if the...
[Deleted]
Hi all, Is there a free way to get historical Rate info data from .NET (C#) application?  Thanks,  
[Deleted]
Morning I am a new member  on mt4 On my chart I have 2 lines   kevinator sell line and kevinator buy line  What are this lines  and how to trade with???  I have not enter indicator as Kevinator ?? Thanks Madrosat 
Hi all. Trying to trade a breakdown of the morning flat on EURUSD and EURGBP. From 23 to 06 I am stretching the linear regression channel and setting targets at 161.8 pro Fib. Stop at the opposite end. The question is, are there any other pairs that have interesting narrowing ranges to trade? It is
Hi, can anybody tell me the software- hardware requirements? I haven't found them at metaquotes...
%K = 100[(C - L10) / ( H10 - L10)] where C = last close, H10 is the highest high in 10 bars and L10 is the lowest low. %D is normally a three-period smoothed average of %K. %D = 100 x (H3/L3) where H3 is the three-period sum of (C- L10) and L3 is the three-period sum of ( H10-L10)
//+------------------------------------------------------------------+//|                                                       helebi.mq4 |//|                        Copyright 2014, MetaQuotes Software Corp. |//|                                              https://www.mql5.com...
does  MQL has memory arragement erros ? MT4 version below 600  accupy  large memory and not release , after complain  ,it is improved . 1/   i also find EA in visible test mode does not match the value designed in EA logicalrism ,ie, if rsi <20,then open buy order ,but ,in the visible mode chart...
Hi, I plot a line into a chart and then I execute a test-script. If the horizontal line is below the price it opens a market buy order and if the line is above the current price a sell market order is placed. Sometimes I get an error #130. I read about it and then I came to the conclusion that this...
[Deleted]
Hi, in https://www.mql5.com/en/articles/1540 a very nice approach is described how to work with files, which are not restricted to the directory locations as with MQL4 file functions.    int _lopen(string path, int of);    int _lcreat (string path, int attrib);    int _llseek (int handle, int offset...
Hi guys   Is it possible in an EA to detect if the broker is a FIFO regulated broker before opening any trades?   Thanks 
How many EAs can be run on the same chart at once? Can more than one EA run on same chart? Thanks. 
Sabbath gentlemen, who wants to play with beta indicators, poke around in the code, and slander the author as usual ;) as they say, welcome. Indyuks are in the attache, add them to the chart and look at available pairs EURUSD GBPUSD GOLD Allow the DL because the indicator is pulling information from
Hello, I'm trying to write a PinBar detector function for the current bar (index 0). The Pinbar_Bar() function will detect the pin bar based on the following assumption: h1= Height of the total bar (difference between current high and low) uc= Distance between open price and current high.  The...
Newbie here, I need help to download the renko charts on my mt4 platform. I tried to google and there were many instructions ie.to download the link and copy everything into the c: metrader / experts / indicators. But I can't find the folder with this directory at all. Anyone can help
[Deleted]
Hello, i want to ask how you change your Sl & TP settings in a backtest over a longer time? I mean I personally cant always use RR for TP and SL (and because it makes the backtest very slow) because of the SL. I tried it with this code: //ATRdouble atr_Ref = iATR(Symbol(),PERIOD_D1,ATR...
[Deleted]
Hi, im a new trader, using demo account in MT4. Yesterday i opened a trade with tp being set, and today morning i checked the chart and noticed that the graph has reached the take profit line multiple times but did not closed. Did i did something in the wrong way? Can someone help me understanding...
[Deleted]
I've noticed some strange behaviour with iMAOnArray() function. Maybe it is the function, but it could also be in the way EAs differ from indicators. Anyway... I was trying to incorporate the TDI indicator into an EA to give signals (rather than use iCustom and address the indicator directly, so...
I am writing a simple EA based on Moving Averages but my code returns zero values. It does not make sense to me. Can somebody help please? Here is the code that returns no values / or zeroes for the variables defined (MAlong, MAmedium and MAshort): MAlong = iMA ( NULL , 0
Hello I'm trying to do something simple, but it is eluding me due a toxic mix of a lack of knowledge and stupidity. With this piece of code, I'd like to print to the log a simple message, once a day, near the start of the day:  bool printed=true;{if(Hour() > 0)   printed=false;if(Hour()== 0 &&...
[Deleted]
I'm trying to identify candles where, a buy candle has more selling than buying, and a sell candle has more buying than selling.  I have the values , but drawing the arrows to mark the candle is a bit of a problem.  The following code is suppose to draw a green down arrow, on the high ,of a sell...
[Deleted]
  Help with EA  (5)
Hi  I have been looking everywhere to find an answer to my problem running an EA on a live account.  When I run it on the live account I get the error invalid lots amount for order send function.  I did not write the program and have limited knowledge of code.  I wanted to see if anyone could help....
[Deleted]
When starting the terminal using an .ini file, the TestShutdownTerminal setting does not shut down the terminal. The .ini file below worked fine on previous versions: ExpertsEnable=false TestExpert=Moving Average Cross - Basic TestExpertParameters=mabasic.set TestSymbol=EURUSD TestPeriod=H1...
[Deleted]
This code will draw an arrow over a candle.   ObjectCreate(StringConcatenate("DwnDSymblD",TimeCurrent()), OBJ_ARROW, 0, Time[0],vH); ObjectSet(StringConcatenate("DwnDSymblD",TimeCurrent()), OBJPROP_ARROWCODE, SYMBOL_ARROWDOWN); ObjectSet(StringConcatenate("DwnDSymblD",TimeCurrent()), OBJPROP_COLOR,...
[Deleted]
In order to study cluster indicators , I wrote a program, which calculates the value of each currency based on the demand for it from other currencies in the market. We are considering a market of 8 currencies: USD, AUD, NZD, EUR, GBP, CAD, CHF, JPY Demand for each individual currency in this market
[Deleted]
Hello,  I have an EA that needs to open positions at a specific time of day, which I want to set externally. This is the (simplified) structure of how I coded it: extern double OpenTime=1.59void OnTick()   {    double CurHour=Hour();    double CurMin=Minute();    double...
I think that traders should decide for themselves what timeframes they want to trade. Not mt4. how hard can it be to add timeframes like forextester 2  (picture).       
[Deleted]
I want to be able to draw a series of lines, 30 pips apart, from the high of the day to the low.  The code below accomplishes this, but no matter where I put the code in my EA, some lines don't draw.  I think it's because of other objects being drawn.  If I keep compiling the code, I get different...
[Deleted]
Hello, hello i want to know why MT4 has many different outputs in backtests? for example i test one EA with a profit possibilities of 10000$, the next day the EA is limited to 5000$ with the same parameter and timehorizon despite i didnt change anything in the code(or i am forgetful?) For Example...