MQL4 and MetaTrader 4 - page 900

  Historical Data  (4)
anybody know how to get historical data? I saw "FileOpenHistory" function but no function on how to actually read the data. any ideas? Thanks Eli
[Deleted]
MT4 used to have a mini terminal that allowed you to enter a position with a SL and TP at one click though i dont have this terminal any more Can anyone help me with this? thanks Dan 
Hello Smart MQL coders, I need some help with this News Breakout EA. Just started learning mql days ago. My idea for this EA is to create both a pending sell and pending buy order at a distance from the price at a certain news release time. I am having problem coding to close out other opposite...
New article MQL5 Cookbook: Developing a Framework for a Trading System Based on the Triple Screen Strategy is published at mql5.com: In this article, we will develop a framework for a trading system based on the Triple Screen strategy in MQL5. The Expert Advisor will not be developed from scratch....
for(i=0;i<=limit;i++)       {          double xy=MathPow(bar/2,2);           count[i]=0;          ave[i]=0;          chazhi[i]=0;          countpingjuncang[i]=0;                                              for(x=i;x<=i+10;x++)                     {...
//+------------------------------------------------------------------+//|                                               台湾鸟-波动率.mq4 |//|                        Copyright 2012, MetaQuotes Software Corp. |//|                                        http://www.metaquotes.net...
Hi  I am creating a buffer of 20 elements to store profit for last 20 ticks .. want to calculate a weighted average from this buffer.  However my buffer variable ProfitBuffer[i] which is declared a global seems not to hold any value. Any ideas why ?  Cheers // Gobal declaration double ProfitBuffer...
  EA Coding  (1)
How can I set the stop loss at certain level of loss (5) and  setting maximum lot size? 
How do I make an EA give comments so that I know how the trade was closed? (like if it was from trading condition 1, 2, 3, etc, which you coded.)
  Please help.....  (4)
Hi everyone,   I'm new here and I would appreciate if you could help me with these 3 questions: 1. I'm developing a trading strategy on FOREX markets which must close all open trades and cancel all existing orders at about 0:00. The easy way to do this is with "if" statement (if timeCurrent = 0:00...
Does anyone know the GMT offset for back testing in Alpari UK? Also, does anyone know if the metaquotes data timestamp is on GMT or has an offset?
Hi, I have created EA thatshould be trading based on the below rules. However something is wrong and Idon’t know what. 1. Buy - Candle Close(2 shift) < Adaptive Gann High-Low activator && Candle Close (1shift) > Adaptive Gann High-Low activator 2. Sell - Candle Close(2 shift) > Adaptive Gann...
i use the EA expert to backtest my EA. But there is some error with the part of code below. the journal said "ticket for OrderModify function must ba an integer". Does anyone know where the error is? double Ticket;  double TrailingStoploss;  double highest;  double lowest;...
[Deleted]
Hello, I have decided to start learning MQL4 and I have created my first Expert Advisor. I just wonder if you can give me any feedback, comments if my approach is reasonable or if there are no unnoticed glitches in the code I have created. Anyway, I would appreciate comments :). extern double Lots =...
[Deleted]
Just downloading and installing Metatrader4 by itself crashes my computer (Windows 7). The installation green bar nearly completes its journey from left to right but stops with less than 5% to go and the mouse is frozen. Not even control alt delete will work. I must shut down manually. This happens
hi.. this is my first thread in this great forum.... i spent two weeks reading threads and trying experts, indicators,scripts...   i want to trade formedium to long term...most of demo accounts offered by companies expired after month...altrade  demo stay for 3 months before expiry but lastly they...
Hi all, I want to discuss about writing a script that could inverse a currency pair. I Got the below script from this topic: https://forum.mql4.com/35535 and i make some changes to get the real data from market. But when you open the offline chart, the output of this script does not update in real...
[Deleted]
Mt4 downloaded from a broker cannot access an account opened by another broker, is it true ? How about mt4 platform downloaded from Metaquotes site ? Can it access any account from any broker ? Does Metaquotes supply free-download multi-terminal Mt4 platform ?
Hello all, I have a simple indicator "_iCustomIndicator" which draw a simple MM ! It works fine ! Now I want to import it into a EA si I wrote : #import "_iCustomIndicator.ex4" at the top of my EA ! Compilation ok but nothing is drawn !!! What is wrong ? Thanks
[Deleted]
Exist other way how identific demo account (besides function IsDemo() ) ?
[Deleted]
As the subject implies, I have a problem running back test on MT4(build 500). Running the same setup on the same(Alpari) data, gives different results. This happens even wwith the MA-sample coming with the installation. Running on 1H(converted from 1 minute) 3 month, 76 trades.  I get both +results...
With my copy of MT4 that I downloaded from MB Trading, I have limited chart history data. On a monthly chart, my oldest candle is for October of 2007. I would like to expand the history all the way back to 1992. How do I do this? Thanks!
Hi all, I'm using 4 instances on an EA and want to prevent for conflicts. The code that I though to use is as follow  if(......)         while(IsTradeContextBusy()) Sleep(10);                       RefreshRates();         Ticket=OrderSend(Symbol(),OP_BUYSTOP,LotSize,PendingBuyPrice...
for example,  double    STD= iStdDev(NULL, 0, maslowLength, 0, MODE_SMA, PRICE_CLOSE, 1);  double    STDma= iMA( NULL, 0,maslowLength ,0, MODE_EMA, STD, 0) ; the journal said " invalid integer number as parameter 6 for 'iMA' function". sorry i am a totally rookie for MT4 programming.
Hi, I am trying to add a MA indicator to the %R indicator so I can have the two indicators in one window. Can anyone help with the script to create this?  
Hi, It would be useful if Metatrader 4 could be updated so that when I click on the trendline object and draw a trendline that the trendline drawing tool is still selected.  It is a pain to draw multiple trendlines.  Each time, I have to click on the trendline tool if I want to draw another...
Guidance needed as I cannot figure out code for looking at total profit value for specific orders in order pool. Looks like my piece of code is too far off..can someone push me to right direction //--orders profit/loss with magicint      Total=OrdersTotal();double   bProfit=OrderProfit();double...
Dear Forum,  It seems there is an error with an indicator located in:  https://www.mql5.com/ru/code/8240 There is 0 divide in the experts tab. Can someone kindly help?  Regards   Thomas
[Deleted]
is there anywhere i can upload and forward test my ea?
hi I am working on an EA that work with renko chart.....i want open just one trade per bar using bar time will not work with me because in renko charts may be more 1 bar have same time! datetime BarTime1 = 0; int start(){   if (BarTime1 != Time[0])  {    //My code         BarTime1 = Time[0];  }...