Download MetaTrader 5

MQL4 and MetaTrader 4 - page 536

To post a new topic, please log in or register
Hi! I normally search for answers instead of asking (I've learned so much from this forum! Thanks to everyone!!!) but... I can't figure this one out. Calling FileOpen returns the handle or "-1" if there was an error. So why do I always see error checking done with: if(handle<1); or if(handle<0);...
Hi all  I'm trying to find out how I can make my EA stop trading after being stopped out at SL.  I found some code on MQL4 that looks usable, but I'm a bit confused about one of the statement, and I'd like to ask you to verify that I understand it correctly.  The code can be found in the following...
Hi people, How can I remove an ExpertAdvisor from chart on MT4 v4.00 build 482? I remember on previous build versions, right-clicking on chart pop-up menu showed "Expert Advisor.." entry and there was an option for removal. But now on this build version, there is no "Expert Advisor.." entry on...
Hi, I connected MT and Excel, MT platform ONLY READING data from excel (one number,cell), only 1x/100-500ms. Reading is ok but after few minutes (1-15min) crash MT. :-( I am using win xp / vista. Is possible somewhere get the reason platform crash? Any log file, ...? Other tools? Any idea...? Thank...
Dear All, I'm converting one indicator to expert advisor. The code is almost complete for BUY order. But it is not working. I'm sure, it's just a small error in the code. Please check that. Thanks
What is the best way to handle the difference between Ask and Bid. When using OrderSend I use Ask to buy and Bid to sell. But when setting take-profit and stop-loss should I also consider Bid and Ask depending upon whether I'm buying or selling. The chart only displays the Bid price so sometimes my...
  Chart lines (5)
Hello. I find it annoying that my chart lines are placed at random levels. For example, my grid has lines on eur/usd (daily) at 12656; 12800; 130840 and so on. Those are random levels. Much, much more useful would be levels from one hundred pips, like 12800, 12900, 13000. Hpow can i have lines at...
HiI have a couple of questions on the behaviour of the strategy tester in the presence of gaps. I did a quick search and didn't spot the answers, however please let me know if these are documented somewhere.I've made some numbers up for the purpose of the question, and I've missed the spread here to...
hi, all a new box came up if you wanted to use one click order. so thought see what it is. problem with this is you cant scall out any more . let say you go in with 2 lots. maybe after some pips you would like to close 1 lot. but that is now not possible anymore with one click order. if you click...
Hi   In the Account History tab in MT4 terminal client, there is an stop loss (S/L) column, where this field has a number and is shaded red does that mean the position was closed by Stop Loss? I think it does.    thanks  
Hello All,  I have trouble with using of iCustom & RSI signal in TDI indicator. I'm using iCustoms like this //---- calculate EMA for the trend recognition        EMA_0 = iCustom(NULL,TimePeriodDay,"EMA",5,3,1,0,0);        EMA_1 = iCustom(NULL,TimePeriodDay,"EMA",5,3,1,0,1);        EMA_2 =...
This is weird! I have downloaded different broker platforms and whenever I fill out an account with them (demo) and choose a server, I am redirected to the fxtm (forex time) site stating "thank you for registering here are your login details" - this must be spyware or some client jacking from them...
i'm having a problem on how to create a script that can open both buy and sell together.. can someone help me? thanks 
I AM LOOKING FOR A WAY TO GET: OPEN,CLOSE,LOW,HIGH,AND PARABOLIC SAR VALUES FROM CHARTS THAT I CAN PUT ON A SPREEDSHEET. ANY SUGGESTIONS??
Hi, i whant to make one ea and i need a code lines: to open a new trade position if the last trade was close with profit . Thank you very much!
I like using metatrader 4 and just started using metatrader 4 mobile. However I am not able to attach custom indicators to the mt4. So far all discussion I saw are does not allow me to do so, does anyone know how to do so? If we are not able to do it now, are there any future development to allow...
Hi guys, Example: I have 1 array ArrayTest [10] [10000] and I need move whole 4th row to 2nd line (rewrite data inside array) My code: for(int j=0; j<10000; j++)                    ArrayTest[2,j]=ArrayTest[4,j];  // I must move each elements from 4th row  exist some better way? Main parameter for me...
In Build 482 an Audio Alert can be muted simply by highlighting the Audio Alert and pressing the space bar. It will stay muted until you reactivate it in the Alert Editor or re-highlight it and press the space bar again. In Build 500, when you use the space bar to mute the alert, it only holds for...
I have been trying to edit my code to use an exact % of the account balance and it nearly does, but is always slightly off... I have tried many different edits and the following code is the closest that I can get... An example would be that on a $50,000 size account a 2% risk loss is $1,500 when it...
Hi everyone,   Sorry if this has already been discussed somewhere but I put my EA on the chart showing a crying face. I am sure the EA is working because if I choose a different broker, the EA is showing a smiling face. e.g. Alpari is showing a crying face and AFB FX is showing a smiling face   I...
Guys, Very simply drawing a rectangle full height of chart. WindowPriceMax()/WindowPriceMin() do not change values when timeframe is changed. int init()  {   ObjectCreate("rect",OBJ_RECTANGLE,0,Time[30],WindowPriceMax(0),Time[50],WindowPriceMin(0));   ObjectSet("rect",OBJPROP_COLOR,Red);...
How do you account for commission when backtesting?
I have been downloading m1 Dukascopy data and converting it into all timeframes to try and make up for gaps in the default metaquotes history center data. Is Dukascopy m1 data more reliable than metaquotes? I am asking becasue results are VERY different on each data with same EA settings so I am...
I have a cci entry criteria when it above 100. However on one platform from my broker this can occur a bar before another platform on the same broker so causes a confliction between the results. Why is this? Surely the value of the cci should be the same and not delayed on either?
I have downloaded data from the history center for Alpari UK amongst others but for some reason the data stops at the start of 2012 but goes way back to the 90's! Any ideas why? I dont want to have to go through the process of getting tick data from Dukascopy especially considering this is limited...
Hi, i have got the fundamental data on a CSV file, and i have brought this data into an indicator, and the indicator is working well in the real time. However when i want to use this indicator in a simple expert and test it in previous time, it gives an error that the indicator can’t open the file...
Why this scrip does not work,. when there is no error  anyone can help ,.  //+------------------------------------------------------------------+//|                        SCRIPT PENDING ORDER NFP...
Hey guys, I found an EA on this site named "pure martingale" posted by gery18. https://www.mql5.com/en/code/10655 I tested it on demo and now i want to make some modifications in it according to my own strategy. 1. This EA opens random trades. e.g; Buy, buy, sell, buy, sell, sell, sell (after...
What does the WPR indicator do for a value when the difference between the highest and lowest is zero? Here is the calculation from the indicator. //----Williams’ Percent Range calculation   i = Bars - ExtWPRPeriod - 1;   if(nCountedBars > ExtWPRPeriod) i = Bars - nCountedBars - 1;     while(i >=...
Can anyone please help on how to publish results of a PAMM, MAM or any standart MT4 account onto a website? Is there any other solution than MT4i. Is there a programm for that? Many thanks in advance for your fast response.