A function to write debug/output text to the Experts or Journal log. Since MQL4/MT4 has no debugger, developers use Print()
(or Comment()
/Alert()
) at key points to trace logic. In MT5, Print()
logs can still be very useful alongside the debugger. For example: Print("Price=", Ask, " ticks=", TicksTotal);
. In c#, an equivalent is Print()
(cTrader’s logger) or Console.WriteLine()
if debugging outside the platform.