Address & Contact

Web

The CLogger class is designed for a simple but effective log utility that can be used to output messages. Message levels, such as INFO or ERROR, allow you to determine their significance. You can specify a level in CLogger, and then only messages of this level and higher will be saved.

The following levels are available:

  • DEBUG: Low-level information for developers.
  • INFO: general (useful) information about the operation of the system.
  • WARNING: warning.
  • ERROR: An error.
  • DEBUG: Low-level information for developers.
  • INFO: general (useful) information about the operation of the system.
  • WARNING: warning.
  • ERROR: An error.

LOGGER_START(minimumLevel, folderName=NULL) – starts the logging function.

minimumLevel: Messages of this level and higher will be saved.

folderName: the path of the subfolder in MQL5Files.

LOGGER_STOP—) – stops the logging function.

LOGGER_WRITE(level, message)-writes a string to a log file.

level: message type.

message: the text of the message.

LOGGER_DELETE() – closes the Logger.

The saved log files are available in the folder (in the terminal menu, click “File” ->” >Open the data file”):

Read More...

MQL5Files

MQL5Files

MQL5IncludeCLogger.mqh

MQL5IncludeCLogger.mqh

MQL5ExpertsLoggerTest.mq5

MQL5ExpertsLoggerTest.mq5

See result on Screenshot.

To call the function correctly, the library should be used in build 670 and higher.

Our Useful Features & Services

Published

07 November 2014

Updated

Current Version

1.0

Reviews

Leave a Review

Price
Profit
Drawndown
Support
Safety
Publishing ...
Your rating has been successfully sent
Please fill out all fields
Captcha check failed