Download MetaTrader 5

MQL4 and MetaTrader 4 - page 515

To post a new topic, please log in or register
Hi, i m trying to call iCustom of a Pivot Points custom indicator that i ve build.   This PP cusom indicator got Daily, Weekly and Monthy Pivot Lines that i m drawing on the chart using objects so i do not need to use any buffers. I use only some global double series of variables like Weekly_P,...
i was held by a strange error for more than two days. After the help of one of my friends, i found that the problem is the result of incomplete historical data. Is it possible to download the historical  data for all the symbols, and how? i am nowdevelopeing a program to scan all the tradable...
When getting a value of the last daily bar using iHigh it returns only rounded number and I need all digits for precision. double high = iHigh(NULL,PERIOD_D1,1); returns 1.329 while the high is 1.32899  I cannot use DoubleToStr as I need the value as "double" for further processing. Any idea how to...
Hi all, is there the possibility that the broker does not accept a pending order if the price indicated is too For instance, the ask price is 125.41 and I want to place a pending buystop @ 125.421, is this a valid request or not? I don't see warnings or messages in the diary and in the expersts tab...
/* Done      by    Rajandran R *//* Author of www.marketcalls.in  */_SECTION_BEGIN("SuperTrend");SetBarsRequired(100000,0);GraphXSpace = 15;SetChartOptions(0,chartShowArrows|chartShowDates);Plot( C, "Close", ParamColor("Color", colorBlack ), styleNoTitle |ParamStyle("Style") | GetPriceStyle() );...
I'm trying to perform a simple spread check before placing trades, but I just can't get it to work.  Can someone help me out?  thanks!!!!   extern double MaxSpread1 = 3;if(MarketInfo("GBPUSD",MODE_SPREAD) < MaxSpread1)     {      OrderSend ("GBPUSD",OP_SELL,1.0,MarketInfo("GBPUSD",MODE_BID),10,0...
Using MLQ4, how can I run an Expert Adviser on one account that will automatically open a trade in a different account?
Hello,    I am trying to come-up with solid functions for opening and closing orders.    Here is the routine for closing I am currently using:    The main issue is I often get error 129, and the routine exits leaving my position open. I won't post the opening function, but it is very similar and...
How can I get an array from a string using MLQ4?  In the code below, the alert is blank:   int start() {    string aPair[];    string Pairs = "EURUSD,USDJPY,AUDUSD,EURCHF,USDCAD,EURGBP,NZDUSD,EURJPY,GBPUSD,USDCHF,GBPCHF";    StrToStringArray(Pairs, aPair);    Alert(aPair[2]);  // Should alert...
I just test this one Comment(" 40%= ", 40/100); it show me 0, why?
How can I remove all non-alphanumeric characters?  This does not work: Alert( AlphaNumeric("Hello 123 !@# WORLD") ); ///// FUNCTIONvoid AlphaNumeric (string istr)   {  string other="Aa";  string ostr = "";  for (int i=0; i<StringLen(istr); i++)  {    string s = StringSubstr(istr,i,1);    if ((s >=...
Carl Lema
Theoretically speaking is it logical to say use a recent time period for in sample optimization and then use a backward time period for out of sample testing. For example optimizing a system on 4H data for 2012 and then use 2011 H4 data for out of sample testing. Will the results of the system be...
Hi all, Is there any code/indy known to be available which would calculate exposure to individual currencies. That is, let's say I am short EURUSD 0.5 lots, long AUDJPY 0.25 lots and long USDCHF 0.5 lots, I want to know my individual exposure to EUR, USD, AUD, JPY and CHF (totals for each). I think...
do i need to be a computer wiz to be able to use meta trader..i friend just let me on to it, and i have to say im a little bit intimidated(that in itself is an understatement)
Hi all,    What I'm looking for is way to get a signal to open orders based in datetime I mean,  if time now is different from time previous then the price will obviously be different and so if  Bid now is n pips above (or down) the Bid of time previous then a condition is created to open an order....
Hi I want a horizontal line on my chart thats always is for example 15 pips fom the price, one line above and one below price. Is this possible in metatrader 4 original functions or do i have to use an custom indicator? In that case does someone know any indicator that will fork for this purpose? 
  Chart pattern (4)
Hello, when we built an EA and we make a back test, we open the chart to see where it works fine or not and try to correct the mistakes... MT4 always opens it's own default chart. With grid and it's own indicators colors... Is there a way to control this? To use the default pattern I have saved, or...
Hello dear friends... I have MT4 on my iPhone 3GS, but iOS 6.1 and everything seems cool, except one thing. There is no the red "TRADE" button there. Only "Chart", "Details", "Cancel". Anyone met my problem and know how to solve it?  Thanks..  ( here is the screen shot)   http://oi48.tinypic...
Hi, Can anyone tell me why the price scale on MT4 charts is not uniform?  As can be seen from the attached image, the interval on the price scale varies. The values and interval are here: Scale Value Interval 1.32925     0.00120 1.32805     0.00115 1.32690     0...
Hi guys, i want to show a text object in the left corner of the chart window but with this code a can never see a text object. What is wrong? I can't find the right solution by myself. int init()  {  ObjectCreate("Text1", OBJ_TEXT, 0, 0, 0);  ObjectSet("Text1", OBJPROP_XDISTANCE,...
  help me (1)
double ma7, ma20, ma65, ma200;   double stoMain_0   = iStochastic(Symbol(),0,14,3,3,MODE_EMA,PRICE_CLOSE,MODE_MAIN,1);   double v1 =iRSI(NULL,0,14,PRICE_CLOSE,0);if(  stoMain_0 > 20 && v1>50   ) siCurrentDirection = 1; //up   if(stoMain_0 < 80  && v1<50 ) siCurrentDirection = 2; //down i want to set...
  Infinite Loop (5)
My second attempt at MQL coding was a designed to extract and display (in the Alert window) some environment variables (min lot size etc etc).  I appear to have cocked this up and now I cannot launch MT4 without it looping and gradually eating more and more memory and CPU cycles.  Is there a way to...
Now I have make a function which can draw line on K lines graphic as below: int LineNo=0;void iDrawLine(int myFirstTime,double myFirstPrice,int mySecondTime,double mySecondPrice){ string myObjectName="Line"+LineNo; ObjectCreate(myObjectName,OBJ_TREND,0,myFirstTime,myFirstPrice,mySecondTime...
I have 2 MT4 accounts, before I log in my second account. I should log out the first account, anyone can tell me how to log out, using android samsung galaxi tab 8.9. Thank you in advance
Just as the subject, the detail is as below: This company which i want to join is trading FX, Gold and Future by EA on MT4. I have studied investment and  speculate about 4 years, but I still work for a biology company during these time. Most time, I want to go to this field (investment), but i...
Hi, I'm writing a code which is used in Visual Mode(F12), it's to simply draw candles of different timeframe.  Say I'm in M15 chart, and I want to draw H1 candles in separate window. I did a test : draw a line with "iHigh", time is in year 2009. It's odd: the indicator line value is actually today's...
I'm so new on mql4 EA. Is there any free EA that can bring daily base profit?   Thanks 
Hi all, The code works fine, but sometimes it fail to start trailing. Could anyone get why ? The Trailing Stop should start to trail once MinimumProfit is reached. I've even change the position of line that makes the Trail start.  The ea is to work with an ECN broker.  Here is the code that works...
I'm slowly learning MQL4 and I would prefer to learn for myself rather than have everything handed to me on a platter. If anyone can help me on the following sticking point, that would be greatly appreciated. I am basically trying to display the current exchange rate of a particular currency pair as...
Hi, my name is Piero and im new to this forum, hoping to get help with this EA. I did find it on the net and was written by Ronald Raygun. I do like the EA a lot, has one flow. The EA opens trade according to the previous candel, therfor is TP and TS worhtless why he opens right after again a trade....