I'm new to the MQ language and I'm trying to debug an indicator - what's the best way to get feedback? I just tried MessageBox and nothing happened, Print doesn't seem to do anything (or I don't know where to look for output). Any assistance would be appreciated.
It's also a problem for me. Right now i desperately use Comment() to debug indicators. It works quite a lot of time but with difficulty like we can get only a single snapshot of current bar, unlike Print() used in expert debugging.
Below Comment() will tell me whether I put the arguments properly or not. All i have to do is go back to the chart and read the value.
ma1 = iMA(Symbol(), Period(), MA1_Period, 0, MA1_Type, PRICE_CLOSE, shift+1);
ma2 = iMA(Symbol(), Period(), MA2_Period, 0, MA2_Type, PRICE_CLOSE, shift+1);
macd = iMACD(Symbol(), Period(), MACD_Fast, MACD_Slow, MACD_Slowing, PRICE_CLOSE, MODE_MAIN, shift+1);
macd_sig = iMACD(Symbol(), Period(), MACD_Fast, MACD_Slow, MACD_Slowing, PRICE_CLOSE, MODE_SIGNAL, shift+1);
Comment(ma1, " ", ma2, " ", macd, " ", macd_sign);
I'll try Comment() - thanks. Maybe we should contact the author and ask him to make something work that writes to a log, or, if it's there, tell us how to use it.