User manual

Table Of Contents
MAUI Oscilloscopes Remote Control and Automation Manual
The following code from the sample file D:\Scripts\Automation\ExampleMeasureSeg.vbs loops over each
parameter specified, returning the result for each segment:
numSegs = 10
for iSeg = 1 to numSegs
set p1Result = app.Measure.P1.Out.Result(iSeg)
set p2Result = app.Measure.P2.Out.Result(iSeg)
set p3Result = app.Measure.P3.Out.Result(iSeg)
outputFile.Write iSeg & "," & p1Result.Value & "," & p2Result.Value & "," &
p3Result.Value & "," & VbCrLf
next
Tip: To see how this works, recall the MeasureSegs entry from
D:\Scripts\Automation\AutomationExamplesLabNotebook.lnb. This will set up P1-P3 and copy a
segment trace into measurement source C1.
Reading from the Measure Table
The sample file D:\Scripts\Automation\ExampleTableMeasure.vbs contains code for iterating over the
Measure table to read results for all active parameters.
Similar code is available for iterating over the Pass/Fail table in
D:\Scripts\Automation\ExampleTablePassFail.vbs, and the WaveScan table in
D:\Scripts\Automation\ExampleTableWaveScan.vbs.
Tip: To see how these work, recall the Table WaveScan, Measure, PassFail entry from
D:\Scripts\Automation\AutomationExamplesLabNotebook.lnb. This will copy a source trace into
C1, set up P1-P6, a Pass/Fail test, and the WaveScan table view.
2-34