Code put in Algowizard:
LogToFile:
Filename: EURUSD_API_DD_log.txt
Message: Long,+CandleCounter,+MaxDD_Lp
// CandleCounter is integer
// MAxDD_Lp is double
How it looks like after mq5 code generation:
How it should look like to save data to the file properly :
sqLogToFile("EURUSD_API_DD_log.txt","Long",+CandleCounter,+MaxDD_Lp);
I suppose there must be some issue with conversion process. It does not recognize commas ( ",").
sqLogToFile function definition looks ok:
void sqLogToFile(string fileName, string st1, string st2="", string s3="", string s4="", string s5="", string s6="", string s7="", string s8="", string s9="", string s10="", string s11="", string s12="" ) {
Subject changed from sqLogToFile is not accepting variables during mq5/pseudo code generation to [127] sqLogToFile is not accepting variables during mq5/pseudo code generation
Type changed from Feature to Bug
Status changed from New to Fixed
Log To File block is supposed to be saving string logs by default.
If you want to save your variables values, try to input following text into Message field:
Long",CandleCounter,MaxDD_Lp,"
Best regards,
Tomas