I don't know how to upload the .dat file, so here is the code. Please note, remove “(indent spaces)” in the code and just add a few spaces in there.
Would appreciate if someone can tell me how to upload .dat files to this forum for sharing.# Macro Metronome
metval = dtmacro.get_metronome()
if metval:
(indent spaces) metval = 0
(indent spaces) showmsg = "off"
else:
(indent spaces) metval = 1
(indent spaces) showmsg = "on"
# dtmacro.show_status_msg_wait(showmsg)
dtmacro.set_metronome(metval)
# Macro Metronome code end