This is a service, which periodically inspects actual swaps for specified symbols and saves new values (if changes detected) into CSV-files. The files are created in folders under the names of corresponding symbols and splitted by months – for example, the file 202410.csv is for October of 2024. Every line in a CSV-file stores a datetime, long swap and short swap.
Also the service check swaps of existing positions and alerts their changes (if any).
The source code can run as a script on a chart if the directive #property service is commented out. But it’s recommended to install the program as a service.
The code base does not support services as one of available MQL5 program types, this is why the program is published as a script.