About the handle being zero:
Yes. Handle could be zero when it cannot create the file due to some reasons(like lack of permission to create the file on disk).
In case you choose to open file in FILE_READ mode(and not FILE_WRITE) handle is zero if the file does not exist.
Hello!
I have below code:
in Mql4 if the file is not exist it will open the file, then at the readData() function it will have nothing to read, and it will move on to the next line.
In Mql5 if the file is not exist it will open the file and then at the readData() function it will read something. Like, first to read should be time, in Mql4 if there is no time recorded in the file, it will not read anything, but in Mql5 it will read 1970.01.01 Why? Also another question, is there any time when the handle can be zero?
"If there is no time recorded" means the cell is empty or there are less cells ? (csv columns)
Anyone? Thanks !

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello!
I have below code:
in Mql4 if the file is not exist it will open the file, then at the readData() function it will have nothing to read, and it will move on to the next line.
In Mql5 if the file is not exist it will open the file and then at the readData() function it will read something. Like, first to read should be time, in Mql4 if there is no time recorded in the file, it will not read anything, but in Mql5 it will read 1970.01.01 Why? Also another question, is there any time when the handle can be zero?