Hi,
i know MT5 save current profile's charts to disk when it is closed, or we can do it manually File->Profiles->Save.
Is there a way to do it via MQL?
I would write a code to save the charts each XX seconds to prevent losing its data if unexpected crash (mt5 or windows or pc) happens.
Thanks.
Read documentation: https://www.mql5.com/en/docs/chart_operations/chartscreenshot

- www.mql5.com
Hi,
I mean save .chr files in current profile directory, exactly as MT5 does when it is closed. I don't need screenshot neither .tpl files.
I can't believe MQL5 don't have such a simple feature...
What you believe doesn't matter. There is no such function to work with MT5 profile.
However a profile is nothing else than a set of templates, except .chr extension is used instead of .tpl and an order.wnd text file is created which
enumerates the charts template. So it's trivial to code your own SaveProfile() function.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi,
i know MT5 save current profile's charts to disk when it is closed, or we can do it manually File->Profiles->Save.
Is there a way to do it via MQL?
I would write a code to save the charts each XX seconds to prevent losing its data if unexpected crash (mt5 or windows or pc) happens.
Thanks.