Download MetaTrader 5

MQL4 and MetaTrader 4 - page 19

To post a new topic, please log in or register
My understanding is that Constants such as Open[], Close[], etc. automatically shift right each time a new bar is created. As does and Double Array that you designate as an indicator buffer. My question is, can you declare your own arrays that will automatically shift in the same way? So that you...
This Indicator does not repaints its arrows after candle close. Very good for scalping on M1 and M5 time frames. Just need to filter with some other indicators. Some one can please add alerts to this indi when it draws buy and sell arrows.
Hi,  Is there any way to plot the Fractals indicator on a different time frame from the current chart? I have tried replacing the High[i] section with the iHigh function with iHigh(NULL,PERIOD_H4,0)[i]. However it doesn't seem to work and says an "array is missing [". I am basically looking for it...
Hi, I've written this short script to open 5 charts on the 15 min timeframe and apply a template to those charts, then open another 5 charts on the 5 min timeframe so that I can apply a different template to those. The script runs but the last part doesn't work. What am I doing wrong? Thanks in...
I want to return the standard deviation of the ATR over a given period.  Trying to do this, but it isn't working. double my_ATR = iATR(NULL, 0, my_ATR_period, 0); double my_ATR_stddev = iStdDevOnArray(my_ATR, 0, my_ATR_period, 0, 0, 0); Any Ideas?
Hi, I would like to prevent that after restarting the MT4 the user will be able to connect to the previously connected account in spite of that in the login window the "Save account information" and in the server options window the "Keep personal settings and data at startup" are klicked on. I mean...
I'm writing a script for MT4 on the Oanda platform and I'm a bit confused. Normally with a 3 or a 5 digit value you would need to convert a Point to a pip by multiplying by 10. When I do this however, I end up getting 10 times the amount of pips. So when I want to set my take profit to 50 pips. it...
How do you get "Date" of specific candle? For example I want to know the date of previous candles. The only solution I discovered to use the iTime() function but it's so weird to me because of it's name time, and not only you get time but including the date. I want to know if there's other way to do...
How to get date of period separator? I have a hard time to get 1 day or I mean 5 days of data in 4hrs timeframe. In 1min to 1hr timeframe I can easily get the 1 day of candles if I compare the current date to previous date but the problem in 4hr timeframe have 5 days of candles, sometimes 4 days of...
Hello,  I`m attaching a file for MT4 EA, I want to know if this file is convertible to MT5 EA? i found this EA is helpful for MT4 and i want to use it on MT5. Thanks
I was thinking if there was a way to code forward tests in MT4 into OnTester() function. It's a pain having to do it manually while optimizing. Does anyone have any idea if this could be done? 
  Dinapoli (16   1 2)
Author said that this indicator is working in two mode: delayed mode (trend is established already) and predictive mode.
Hi! I'm having a very strange problem when trying to access the close price of the candle in another timeframe. Sometimes the value comes right, but sometimes it comes wrong. Any idea what might be happening? Code: input ENUM_TIMEFRAMES     UseTimeFrame  = PERIOD_D1;Print(iClose(Symbol()...
Hi Everyone, I'm looking please for a simple indicator/ EA able to add a sound alert (plus eventually a popup alert) when a Horizontal Line placed on a chart is being triggered at a certain price. Any suggestion, please? Thank you! Paully
Hi I'm sorry if this is a stupid question, but if I have multiple timeframes open for the same currency pair, with different EAs running on each of them, how can I tell which EA actually triggered the Buy/Sell order? Edit: Sorry, just realised if I hover over the order in MT4 I can see the expert ID...
Hi, I've searched the internet in general and this forum and I cannot find an answer to my problem(s). I am trying to run an EA (M1) in the Strategy Tester (ST) and have an offline chart (M5) update beside it but I am getting no-where after several weeks of trying to figure this out.  HELP! Select...
Hi guys, I'm trying to debug my EA on history data and the option on the menu is always disabled. I see it works fine with real data. I already did the necessary setting under Tools -> Options -> Debug tab and the menu option is still grayed out. I found some old topics about this subject but they...
I am trying to download historical indicator data and open/high/low/close values to a .csv file.  When I run the following code on an offline GBPUSD 5 minute chart (see screen shot) I am not getting the values I see in the chart.   Here is the last line in the .csv file which matches the datetime of...
Hi Newbie here... I'm trying to write an EA that returns two values from a function. Can't seem to get it working... Any help will be much appreciated. Thanks.
Hello,  i am having trouble with my trades. I dont know if it's the EA or the broker am using that causing me problems. All my trades are opened 4 to 5 pips away from the previous bar's close. I understand there's slippage but 5 pips away from the close is just too much. the ea reads a decision from...
Grid switched off as default when opening a new chart. If possible i want to customize the default color of candles too.
Hi everyone, I need help to build up my strategy. I used that Idea with manual trading andit`s profitable. So now I need to have it automatic. I would really thankful if anyonecan code given below strategy. Basic Trading Strategy : # Check previous candle high value. Place pending buy order...
Hi, For the past week weeks I have been observing very weird look of candles on different trading symbols' charts. The problem seems to be that candles don't even form or barely start to form correctly. I haven't seen any major internet connection problem with MT server so I don't understand what...
  Order event (1)
I would like to know to handle an order event. For example, when an order is close then it will automatically alert a message. Thanks!
Hello all, my question is if this function is stated correctly? int Pips(){                double Pips = Point;             if(Digitos == Cinco)         {           Pips = Point*10;            return(10);          }        else if(Digitos == Cuatro)         {            Pips = Point;...
I've got an EA set up against a demo account (and then uploaded to the MQL VPS service) It should be using iHigh and iLow based on the first Candle to determine a range and then uses these as SLs (plus a few pts) to set up 2 orders But as you can see from the picture it seems to be using wrong...
Hi, can someone explain me difference between "Bid" and MarketInfo(Symbol(),MODE_BID) ? I used "Bid" value for some open positions and when I wanted to check opened position with OrderSelect it didn't find it and that order was opened with that price "Bid". After that I started to use...
i can not able to create OBJ_ARROW in  indicator_separate_window. But i can able to create OBJ_LABEL. please help me to fix the problem. I found reason for that. OBJ_ARROW still at Time 1970.01.01 00:00 and Value: 0. it not taken OBJPROP_XDISTANCE and OBJPROP_YDISTANCE. my codes is: #property...
Hi all, I have download mt4 from MTrading, it work well but is not perfect. Now I'm trying to add a new indicator (advanced adx) but when I drag file into the folder it's not possible to drop it, it's like mt4 doesn't recognize the validity of the indicator that I want to add. I ask you if someone...