Was trying to bring the value of ZigzagBuffer in my EA by writing the value to a file, in the indicator and then reading it from the file, into my EA. Was able to write to file, but when trying to read, I get error code 5004. Below is the code I used.
- ICustom Question
- Problum in reading text file
- Equity oscillator by MQL5 means
Yellowbeard: Was trying to bring the value of ZigzagBuffer in my EA by writing the value to a file, in the indicator and then reading it from the file, into my EA.
Was able to write to file, but when trying to read, I get error code 5004.
- Why are you doing that instead of just reading from the buffer with iCustom? Detailed explanation of iCustom - MQL4 forum
- You wrote the file "ZigZagBuff"
ZigzagBuffI=FileOpen("ZigzagBuff", FILE_CSV|FILE_WRITE, ';');
- You try to read the file "ZigZagBuff<space>.txt"
ZigzagO=FileOpen("ZigzagBuff"+" .txt",FILE_CSV|FILE_READ,';');
- And you wonder why you get:
5004
ERR_FILE_CANNOT_OPEN
Cannot open file
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register