writeMsg method

void writeMsg (String msg, [ String transformMsg(String origMsg, bool flag) ])