Download MetaTrader 5

MQL4 and MetaTrader 4 - page 2

To post a new topic, please log in or register
Hello,  Does anyone know of an ea or another way to record running equity values from mt4? I'd like to record equity values every 5 minutes or so in order to do some analysis, but I haven't been able to figure out a way.  Thanks
#Article and Forum for Beginner & About Trading Strategy - Open H‌ello, ‌‌I already found few articles that I will read all of them before I start to write code for my first Trading Strategy EA's.‌‌ But I think if someone ( professional coder or programmer ) will share some links about Trading...
Good evening, I would like to ask you if you can make the following code in mql4, as I can not program it myself. The function is: "after X bars exit the first opening in profit". Sorry for my bad english. Thank you, I hope you can help me.
Hello, I tryed today to test my EA with ICMarkets MT4 Demo account, but oldAsk variable which will be settetd on JFD MT4 Demo will be not setted. I created 4 values stack which will be filled with ticks. In oldAsk I store tick which was 4 ticks before. For diagnistics I added Print() function. And I...
  Indicator Miscellaneous Questions (129   1 2 3 4 5 ... 12 13)
Hi, #Broker Time   I spent few hours for reading some comments, but I did not figure out how can I set my Broker Time to my indicators / how can I set my indicators to my Broker Time. (maybe I confused) My Broker Time starts from 01:00, but all my indicators works from 00:00. So how can I solve my...
Hi,  I try to use 'else {}' code when market closed just it could play. But two sounds mixed, where is a problem, please? // SELL if( sparam == "SELL GROUP" ) {     ObjectSetInteger ( 0, "SELL GROUP", OBJPROP_STATE, false );     _ticket = Order  (    "SELL GROUP"                       );...
Dear Friends I just build an EA for autotrade. But I cant upload it to Market due to this Error 131 occur. Please help me to resolve this. What should I do for overcome this Error. thank you.
Hi seniors, I come into a problem where by when I use the same code in creating indicator and expert advisor, the system give me different result. In indicator, which the result is correct, the following code will give me:- result = iMAOnArray(priceSeries,0,5,0,MODE_LWMA,0); input = priceSeries =...
Hi,    I am using mt4 for automated trading.  I put mt4 on the cloud computer. I use rdp to log in to manage my cloud computer. I found that remote login using rdp will occasionally cause my mt4 program to terminate abnormally. What is the problem?
Hi, guys! I already got accustomed to surprises with every new version of the MT4 platform, but this one is really frustrating: struct Util_32bytes { uchar data[32]; };struct Util_4ulongs { ulong data[4];  };Util_32bytes raw;Util_4ulongs long4 = raw; This code should work according to the...
Hi,   I've been searching through the articles, and I've written a couple of Expert Advisors.   I would like to incorporate built-in Indicators into a new EA I am writing.  (I hope these questions aren't dumb). How do you force a draw on your current chart of a built-indicator?When you force the...
Hi, I want to do a bot that will do these steps : When i open an order ( for example in long position) and the price reaches a X number of  pips close in "take profit". But if the price go down of X number of pips open a new order in sell. How can do it? Thanks and sorry for my bad english. P.S :...
  Usefull links/threads/tools (35   1 2 3 4)
The thread about threads: what's going around the forum everywhere  ============ Requests & Ideas The beginning Requests & Ideas, the beginning - the thread  After Requests & Ideas (MQL5 only!) - the thread ============ General rules and best pratices of the Forum thread ============ Traders joking...
Hi, I (mt4 b1065) created 10 little rectangles at the lower right corner and and changed their size acc. to the image  BUT, they do not appear as objects in the object-window (ctrl-B)? Anybody else with this experience? Beside that I cannot (de-) select them e.g. do delete them manually.
Hi, the indicator below stopped working a few days ago and I'm struggling with the problem. I attach the indicator which is not auto-refreshing the arrows and also the EA in which you can see the indicator is always returning the value "0". Indicator #define VERSION "2.0"#property copyright...
Hello guys. Can you tell me if the code in this way can be correct or where i`m doing wrong? Thanks to everyone.     //++++ Spread Filter    extern double MaxSpread = 5.0;    int MarketInfo()        if {(StringFind(Symbol(), "JPY") >= 0){ {Spread = (Ask-Bid)*100; } else {Spread = (Ask-Bid)*10000;...
Hi Im new in Mql4 and Im trying do this Variable Lot: Ordem 1 :  0.01 Ordem 2 : 0.02  Ordem 3 : 0.01 Ordem 4:  0.02 ...... Can anyone help me ? Tks
In my EA I am getting the error message, "possible loss of data due to type conversion", for both occurrences of "prevtime = Time" at the end of the EA code below: #property strict// EA Inputsextern int    TrailingStop   = 20;extern int    StopLoss       = 0;extern double Lots           = 0.1;extern...
with MT4, I'm trying to create a custom indicator that, once I placed RSI indicator, put on it also the MA indicator. Manually I add RSI chart indicator, then 1) I drag&drop MA indicator and select Apply to: First indicator's data and then I click OK. 2) Then I reopen in editing this MA and change...
I'm using Wine in Debian Linux. I can't get it to find the common data file "com" which I have placed inside /home/l0l/.wine/drive_c/users/x/Application Data/MetaQuotes/Terminal/Common. Print("TERMINAL_COMMONDATA_PATH = ",TerminalInfoString(TERMINAL_COMMONDATA_PATH)); The previous command yields the...
Hi, I utilized an indicator, saved the template (hi.tpl), and then tried to load it but it doesn't work. I always received error number 5002. Any advice?                  long   Chart_ID[1]                  Chart_ID[1]=ChartOpen("EURCAD",15); //1                  bool x;...
  data window? (2)
Is there a way to edit what you see in the MT4 data window box? I would like to add time to my data window. Right now I only see the date, and OHLC prices - can I add the time? If so, how? Please and Thank you everyone. 
Hi all, How do you clear the cache?  Or are there any issues with the MT4 that would cause the platform to slow way down?  I have assumed it the cache needed clearing but there may be another issue?  Thanks.
Hello! I have an EA, that works with RSI. Now I want that the EA, by adding to the chart, automatically opens an indicator (RSI) subwindow with the specific parameters provided by the EA. I was trying "ChartApplyTemplate", but imediately this function removes the EA: "The Expert Advisor will be...
Hi, I need an EA/indicator to communicate with each other to add and bring a control of the equity of two MT4 terminals My strategy is a hedge between two mt4 and I would like (since my broker does not support multiterminal) I would like to keep a control for days/weeks on the benefits between the...
Please tell me how to get the time of the highest 5 minute TF candle during the last day only?? thank you for assist .. 
  ex4 to mq4 (13   1 2)
I have this scalping ea that is in ex4 format.It will not work on mt4 platform.Can the ea be converted to mq4,if so where.
I managed to open charts automatically using OpenChart() function. The question now is how to automatically Apply an EA to charts using MT4 functions. I need to select an EA and a setting file and then apply them to a chart ( or a number of charts). Is that possible? Code? Thank you in advance. 
In my EA I am getting the error message, "possible loss of data due to type conversion", for both occurrences of "prevtime = Time" in the EA code below: if(Time[0] == prevtime)                  return(0);        prevtime = Time[0];        if(!IsTradeAllowed())                 {...
Hello, I am trying to get the high value at a certain period of the day. For example, when it is 11 pm, I want to retrieve the high value at 6 pm To do so, I use iBarShift() to get the shift and then apply iHigh() to this shift The problem is that very often the iBarShift returns -1 meaning...
123456789...1231