Forum

mt5 history for pairs calculation

Hi everyone, I have always programmed in mql4, now I am using mql5. I have a problem: I am doing tests for an expert advisor that trades two pair at the same time (spread trading). To use qualitative data, I create custom symbols . However, for example, when I have to test the AUDCAD - AUDCHF pair

Mt4 blocked if not updated.. it's not normal!!! crazy

Good morning, I find it absolutely absurd that if I don't log into my vps for a while I can find myself with mt4 BLOCKED because it doesn't update. Incredible, that is, do I have to risk my experts not closing my operations just for an update? Are we joking? but who is the genius who decided that

Problem with average price and trailing stop

Hi everyone, I'm making an EA that uses a grid with trailing stops, to do this I use a function that calculates the average price of orders. Then I use it to move the stoploss of all orders when the price exceeds the average price + a certain amount of margin pips. All this does not report errors

Indicator does not enter for loops correctly when I change timeframe/asset

Hello everyone and thank you in advance for your help. I wrote an indicator that, based on the opening and closing conditions of the past bars, creates rectangles in the chart. The indicator works well most of the time and updates correctly on the chart. The problem occurs when I try to change

Help with array and object delete

Hi everyone! I'm trying to create an indicator that identifies some price zones that interest me. I was able to create it perfectly and the logic works, the only problem is that I would like to eliminate the price zones that are invalidated (ie exceeded) but it is proving very difficult for me. I've

Different results with same code, same prices, same tester...?!

Hi everyone, I've been writing an expert advisor for a while that I tested and optimized using Alpari. But now, I realized that after some time, without any modification to the code, the tester results are different (the original DD was 8%, now more than 40%) even if the dates are the same, the

What impact video card / monitor resolution have on graphical objects?

Hi all, I created a dashboard for my expert advisor using graphical objects. I decided each object's position and size using OBJPROP_XDISTANCE, OBJPROP_YDISTANCE, OBJPROP_XSIZE, OBJPROP_YSIZE. Since monitors with different resolutions are not available, I wanted to understand if in some way the

Problem with BMP object in Mql4

Hi all, I'm trying to insert a BMP object but even if the object is created correctly and I have no errors in compiling, I don't see it in the chart ( but i see on object list ). I can't find the error, thanks to whoever can help me. The file is 24bit in bmp. #resource "\\Images\\test.bmp" void

Compare two indicators

Hi, on mt4 it is possible to combine two indicators in the same window, for example the moving average on the standard deviation . But how is it possible, by programming, to compare the position of these two indicators with each other? For example if the moving average is above the standard

Programming in MQl4 on Linux : your experience?

Hi, I had in mind to create a partition only and exclusively to use linux, I wanted to know from your experience if anyone uses it to program in mql4 and has had some kind of problem. For example, I use the MT4 in a portable version and download the historical data from dukascopy (like many of you I