MQL4 and MetaTrader 4 - page 30

To post a new topic, please log in or register
Hello, I noticed that in order to read data from an attached chart, I can use CopyHigh() function, for example. Everything is OK when I try to get chart datas of a recent, for example datas of May 3 2018. But when I try to get chart data of an older date, for example May 3 2005, I always get 0.0...
good morning everyone, I created a simple EA that reads the positions from CSV and executes the orders. would it be possible to open positions of symbols other than just one EA? I try to explain myself better, create a script / EA and attack it to a chart, for example EURUSD, it would be possible...
given the following two arrays: string symbols[]=      {       "USDCHF","GBPUSD","USDJPY","EURUSD","AUDUSD","USDCAD","EURCHF","EURGBP",       "EURJPY","EURCAD","EURAUD","GBPCHF","GBPJPY","CHFJPY","NZDUSD","NZDJPY",       "CADCHF","EURNZD","AUDJPY","AUDCHF","AUDCAD","AUDNZD","CADJPY","USDSGD",...
Hello, I have an expert and I would like it to make a WebRequest to verify the current version number of the expert, and alert the user if there is a newer version. I am wondering if there is a way to add the URL to the Allow WebRequest from inside the expert. I assume this may be a security issue,...
hi i just downloaded indicators but they do not open up in my charts on mt4.  nothing happens when i run them am i doing something wrong?
Hello, I have some issues loading historical data. I want to test an expert advisor for which I need lots of 1Min Historical data. 1. When I keep pressing the home button on the 1 min chart to load more historical data, there is only a few weeks back I can go to. After that, pressing the home button...
Hello to everybody... I would like get the integer part of a double number, so I guessed to use the library function MathTrunc() (https://www.mql5.com/en/docs/standardlibrary/mathematics/stat/mathsubfunctions/statmathtrunc) but such function is not recognized by the compiler. How could I use it ?
Can somebody help me how to make a program in MT4 for plotting dynamic horizontal line (such as for High/Low), dynamic vertical line (such as for date) to chart...?Thanks for any kindly help :)
I have loaded an EA on my mt4 platform.  When I try to put it in my chart I get an error message that says its in my library stdlib.exe4 When I go to the dependencies part of it I get a message under the library exe that says STRING ERROR DESCRIPTION (INT) Can somebody please help me fix this issue?...
MT4 Error code 4060. Can anyone tell me what the cause of this is.
Hello! i just got a much lower price on the stop sell price i placed. How do i set it on MT4 that if market price differs too much of an amount, orders will not be executed? Do i go to the Deviation setting on MT4? For the Deviation setting (i am on a 5 decimal place broker), say i set it to 30...
mar5
As an example, I scan for fractals. As soon as a new fractal is formed an alert pops up. I do this on different timeframes. But when I open the terminal I would like to know where the last fractal is. So I have to loop back. But I need this loop just once. Then the indicator scans for real time...
  MT4 (5)
Hello, I just realized that on some currencies you could see info on entry price, take profit and stop loss information.  Is there a way I can set an alert on my choice of currency to know when that information is available for time to enter market and the tp and sl information? Thanks,
I'm using metatrader to deal Stock market assets. When I see the default value on the chart, do I see the BID VALUE or the ASK VALUE?
Or is a separate EA for every _Symbol or maybe _Period  better or more precise for some reason? Logic suggests using one EA is more efficient than attaching the same EA on 20 different charts because the simple act of loading many different charts seems to lag the platform. Is that all there's to...
Hi, all. I just wonder why I suffer slippage when I close the order. My OrderClose() function is like below. OrderClose(OrderTicket(),OrderLots(),TargetPrice,0,Red) As you can see, I defined the target price (like a limit order) and I allowed '0' for the slippage as I didn't want to close my order...
Trendline or Horizontal line order after candle Close : after take order Trendlin change its Color and Deactive
Hello, I am trying to code my system however after compiling it returns the "not all control paths return a value" and when I double click it shows its in the following block, could someone please point out the problem. Thank you in advance bool CalculateCurrentSellOrders(string symbol)  {   int...
Hi all, I've read thru the MQL4 documentation and it all seem'd to be quite straightforward for developing own EA's or indicators. Anyway, I couldn't find any documentation on how to develope an EA or an indicator that would use data and from multiple time frames, for example 5M, 30M and 4H....
Hi everyone,   I have one trading system which I'd like to have as EA. This system is based on renko charts and mindhero indicator.  Why am I using renko charts? The reason is simple. Renko simply filters choppy market. Also it is very useful during news (I'll show you what I mean in example below)....
"The function returns the amount of bars not changed after the indicator had been launched last." What constitutes a 'change'? Can the fact of the bar closing be considered a 'change' - the bar was open, now it is closed... the bar was index 0, the bar is now index 1 - surely this is considered a...
Hi, I am trying to store highest and lowest values of a wave ( from zig zag) and copy into buffers. I am then comparing if it is a highest high and highest low from its previous then alert will display that it is an up trend but problem when I compare them I am not getting any alert, I think I am...
I have a couple of MT4 running on my computer. I was just modifying some settings in one EA and all of a sudden MT4 shut down. I tried to start MT4 again, but nothing happened when double clicking the icon. I restarted my computer and tried to start the MT4 again, but with no luck. All the other 4...
Hello iam trying to load an Expert Advisor with start.ini file from cmd like this: terminal.exe config\start.ini start.ini includes: ; open chart and run expert and/or script Symbol=EURUSD Period=H4 Template=popular.tpl Expert=MACD Sample ExpertParameters=macd.set...
Hi everyone. I am new in fx trading. I wanted to test EA bot but I failed. Can someone help me? Problems: 1) I can't find EUR/USD pair in History Center. (Image is inserted below). 2) I tried with other currency CAD/JPY in an M15 time-frame, and guess what? I failed. tester show me he is running...
so I got this ea online, but when I apply it to a demo account it does not open any trades. it does however open trades in the strategy tester. I have even looked at the code but cannot figure out why. it works it the backtest but not in live or demo, i wanted to have it hedge the trade so to speak...
This code is taken directly from the manual/tutorial in the Custom Indicators section - https://book.mql4.com/samples/icustom I cannot seem to understand how it is that 'IndicatorCounted' (Counted_bars)  can equal anything other than (Bars-1), unless the program is on its first iteration of the...
I downloaded the MQL4 Book by Kovalyov: https://book.mql4.com/content I was able to right click Properties > General tab > Unblock on the file to make the file readable. But now I got to keep clicking on bottom page links to go to the next section, as opposed to just flipping pages back and forth...
I wrote anEA for MT4 that should open at the same time 3 trades for 3 different pairs.  On demo account, when volatility is high there is a delay of 20seconds between order open times, same happens for order close (orders should closeat the same time)   void ……….()  {  SO_EURUSD=OrderSend("EURUSD"...
Hello, I've searced everywhere but didn't get 100% answer on the question: What is the correct CSV format for MT4? I am calculating custom CSV and trying to convert it to FXT and HST(with Birt CSV2FXT script) but the script i sayng that the data have too many errors. I run the test in 15M visual...