Transiently replace the debug window with a printed debug message
RGerkin
function TestDebugToggler()
UnDebug()
FuncWithRTE()
PrintDebug()
ReDebug()
end
function FuncWithRTE()
make /o/n=101 test
fft test
end
function UnDebug()
DebuggerOptions
newdatafolder /o root:Packages
newdatafolder /o root:Packages:DebugToggler
variable /g root:Packages:DebugToggler:debugOn=v_enable
DebuggerOptions enable=0
end
function PrintDebug()
variable err=GetRTError(1)
if(err)
print GetErrMessage(err)
endif
end
function ReDebug()
nvar /z debugOn=root:Packages:DebugToggler:debugOn
if(nvar_exists(debugOn))
DebuggerOptions enable=debugOn
endif
end
UnDebug()
FuncWithRTE()
PrintDebug()
ReDebug()
end
function FuncWithRTE()
make /o/n=101 test
fft test
end
function UnDebug()
DebuggerOptions
newdatafolder /o root:Packages
newdatafolder /o root:Packages:DebugToggler
variable /g root:Packages:DebugToggler:debugOn=v_enable
DebuggerOptions enable=0
end
function PrintDebug()
variable err=GetRTError(1)
if(err)
print GetErrMessage(err)
endif
end
function ReDebug()
nvar /z debugOn=root:Packages:DebugToggler:debugOn
if(nvar_exists(debugOn))
DebuggerOptions enable=debugOn
endif
end
Forum
Support
Gallery
Igor Pro 9
Learn More
Igor XOP Toolkit
Learn More
Igor NIDAQ Tools MX
Learn More