Forum

ChartNavigate function doesn’t work, Please help

I can imagine that this is suppose to be simple, but I just can’t get it working. This simple code: ChartNavigate ( 0 , CHART_BEGIN , 4000 ); Print (time[ 4000 ]); Rather than scrolling the chart to the bar number 4000, it scrolls the chart to the beginning. The line “Print(time[4000]); ” just give

TimeToBar function

I’m wondering if in MQL5 there is any function returning the Bar number given a DateTime value. For sure some similar function is used when creating an object (“ObjectCreate”) on the time parameter, and if that time doesn’t exist the object is created on the first previous Bar. Obviously I already

Holidays List

Hello there I’m looking for a reliable list of forex Holidays for 2010 and 2011. The intention is not to open any position during holidays on my back testing and expert advisors. I’ve been dealing with lists I found on the web and as result I got my brain melted. This are the best lists you can find

From Datetime value get uint or ulong number of seconds elapsed since January 01 1970, and vice versa.

We all know that the Datetime type is actually storing the integer number of seconds elapsed since January 01 1970, but it seems there is no function to get access to this particular value, or to get a Datetime value given the number of seconds elapsed since January 01 1970. Do you know any good way

How to declare dynamic arrays

I really looked everywhere but I can’t sort it out. Could you tell me why a code like this one int Array[][ 15 ][ 15 ]; Array[ 1 ][ 1 ][ 1 ]= 256 ; Print (Array[ 1 ][ 1 ][ 1 ]); is giving “Array out of range” error? All my researches bring me to “Dynamic Array Object” on MQL5 references, which

Creating files outside the terminal path.

Hi there I'm doing mass testing with resulting massive size files. I have a small pc hard disk. I'm desperately trying to handle these files on my external terabyte hardrive, but I can't find no way to specify in MQL5 a path outside the terminal. Is there any way to do this

How to create my own charts without any symbol inside

Hi there the idea would be to represent on the way I like in an empty chart, free of any Symbols, arrays data stored in a BIN file, or any other calculation. Basically I need an indicator without the symbol chart on the top and (even better) the option to choose the data type for the x and y axis

Double and Float variables accuracy issue

Hi everybody this is my first time on the community. Hope not to bother anybody with silly questions. I noticed that doing many operations with Double or Float variables returns imprecise results. I created this simple code as example: double x; float y; int filehandle= FileOpen ( "File.txt"