94
Chapter 9
Measurement Applications (Sample Programs)
Setting Up Measurement Conditions and LCD Display
ErrorCheck viVPrintf(Agte4981a, "AVER ON" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "AVER:COUN 4" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "TRIG:DEL 0.001" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "DISP ON" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "CALC1:MATH:STAT ON" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "CALC1:MATH:EXPR:NAME PCNT" +
vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "DATA REF1, 1.0E-8" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "CALC2:MATH:STAT OFF" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "CALC:COMP:BEEP ON" + vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "CALC:COMP:BEEP:COND FAIL" +
vbLf, 0)
ErrorCheck viVPrintf(Agte4981a, "*SAV 1" + vbLf, 0)
'===================================
' Setup End
'===================================
Call viClose(defrm)
End
'===================================
' ErrorProc
'===================================
ErrorHandler:
' Display the error message
MsgBox "*** Error : " + Error$, MB_ICON_EXCLAMATION
End
End Sub