Download MetaTrader 5

MQL4 and MetaTrader 4 - page 1047

To post a new topic, please log in or register
Hi: I am interested in accessing some of the native MQL4 functions from inside my DLL code: mainly to allow the reporting of error messages or status. Here is a simplified example of what I would like to do. Note that it is an oversimplification for demonstration purposes. In actual practice the...
Hi, i use a Void function to make a margin check before opening a new trade.>1500% ok for open, <1500% wait for next tick. When margin low the check applies because i see in journal Margin Check Failed, but the order is then opened. Has someone an explanation? //---- Margin Checkvoid...
Can anyone help me with this? I have written the following while loop. The idea behind it is that it keeps updating winprice and looseprice with the current Ask price until the current ask price is equal to the stop loss or take profit. However it goes into a endless loop, because the Ask price...
How exactly do you compare for example if the two(or how many ever) previous bars are lower or higher than the current bar? I guess basically what I need to do is compare previous prices with current prices to generate a buy or sell signal. I thought I could do it this way, but it doesn't seem to...
Can someone direct me to a resource that lists the decimal values for each color in the color table?
I'm in the early stages of writing a new EA and I am shocked by the variability in the processing time. For example, I am currently calculating and printing only two MA's and sometimes it takes only 1 second, then sometimes it takes 24 seconds. My guess is the EA must interact with the broker's...
Hello, Newbie here...I want to make a simple indicator that I can input 2 numbers, 1 for a fast MA and 1 for a slow MA (both simple) that will draw the lines and dran an up arrow when either the fast or slow ma turns up while the other one is turned up. The indicator I have written gives me an...
What is wrong with this Platform ? Connected to FxPro Demo.NB at 4770/5k speed
I want to change showing number on the chart like picture... Is it possilble ?? 1.38105 -> 1.3810 decimals
For the build 221 update, what happens after you get the pop-up window asking "Do you want to allow the following program to make changes to this computer?" Click "yes" and nothing happens. Is there something else that needs to be done. Um, yes I know it's beta and all that stuff, and this is only...
Does anyone have an ADX sound alert indicator where one can set alert levels.  Eg: ADX crossing the 25 level.  There appears to be plenty of adx +/- crossing indicators but so far I have had no luck in this particular quest. I would be grateful for any pointers on this one. Cheers
New article Fallacies, Part 2. Statistics Is a Pseudo-Science, or a Chronicle of Nosediving Bread And Butter is published: Numerous attempts to apply statistical methods to the objectivereality, i.e. to financial rows, cannot overcome the nonstationarity ofprocesses, "wide tail" of accompanying...
FileWrite(handle, OrderPrint()) will direct the output from OrderPrint to the screen first and then FileWrite the number 1 to a file. How can I get the OrderPrint() output to a file? I'm aware there are other longer ways of achieving the same thing, so my question is specifically regarding...
same as above, i try to google it but still dont have clue about it, i hear somebody say it is very profitable once u understand it so i wonder does anybody know what they are
In order to calculate the MA slope, I need to obtain the MA value from a few periods back, say 5 periods prior to the current period. As best I can tell, the "shift" parameter in this function is the means for obtaining that value, and I have used "5" for that parameter. However, it does not...
Dear Programmers! Can I use buttons in the EA? For example I would like to create a button which immediately open a determinate trade. It can be on the chart or anywhere else. Thank you. Relative
I have an indicator which draws one line. The line is sometimes green and sometimes red. Is there any function to get a color of the line? I tried with ObjectGet(name, OBJPROP_COLOR) but I don't know the name or maybe indicator's line is not an object? Marko
Please, help me to resolve this problem: I'd like to count the total amount of profit that belongs to a magic number (there are other orders with different magic on the account). Here is my code: double MagicProfit(int Magic){  int total=OrdersTotal()-1;  for (int cnt = total ; cnt >=0 ;...
  Logic for EA (2)
One of the indicator in my EA I am using is the Bollinger Bands... One of the check is to go long when the Ask is above the upperband by 5pips. Now lets say, my EA finds all the checks to be good including the upperband check. The buy order is placed and lets say, I exist with 20pips profit. At...
Hi. I've tested my expert for some time. The expert uses muliple time frames. I've added some time frames and now the expert keeps on loading ie the 30min start over and over. I can see the memory usage going up as the chart is loaded over and over. I tried to remove the one that being loaded over...
Hey everybody, i would like to use some information of this custom indicator. I need to know, how to get the collours out of this indicator in an EA. I tried to use icustom, but this one gives me only the value of the indicator. is there another way to get some variables out of the indicator, so i...
I have read the document to try and get a grip of how this works, however i need to see a really basic example in order to have a starting point. If anyone could help me with this i would be very greatful. All i would like to see is the absolute minimum lines, a basic start, buy point, sell point,...
Hey everybody, i have a problem, that my datetime test = globalvariableSet("xxx", 2) test is allways 0, which means my globalvariable was not set. can you tell me how and why? thanks
Hi there, can any one help me please.... I want to filter a trade entry like this : 1: If the Bid price is lower than or equal to the low on the last hourly candle && 2: If the Bid price is lower than or equal to the lowest low of the last two 15min candles -8pips then enter short... I...
Currency, time frame and open, close, high and low are shown on left hand top by default. Is there any way we can delete this and show Currency and Timeframe on right hand top.
Hi! I have opened a mini account at FXDD demo with leverage 200:1, but my EA doesn't work because of error 131 (wrong trade volume). It says Lots=0.1 (Lots=MarketInfo(Symbol(),MODE_MINLOT)). Why not 0.01 (mini account)? How can I resolve this? Thank you!
I have not used MT 4 or any other version of MT. I am considering changing brokers to one who offers MT 4 as their platform. First, is there a user's guide I can download in PDF form? I know MT has an "online" help option, but I like to have a book in my hand. My first question about the platform...
What s the best strategy tester model?
Is there an EA that records and reports on the spreads that are occurring on a specific pair? ie. EURCHF. KeithN
I need to know if is possible to set an alarm on this indicator 0_WolfeWave_4m The problem is that I have only the Exe file.......
1...104010411042104310441045104610471048104910501051105210531054...1250