When reporting Cloud-to-CAD it is possible to display the Min / Max / RMS / Profile / etc. however only the individual Point X, Y, Z, or 3D value(s) can be set to Variable using the GetReportInfo() VB command like this:
- MyVar = GetReportInfo( "Cloud-to-CAD Deviation", "CLOUD1:P1:3D" , 3 )
However using VB, it is possible to count the points in the Cloud and then set each individual 3D deviation to a variable and finally identify the high and low points.
Considering the following report item:
You could use this VB Script to set variables containing Min and Max deviation:
- NumPts = GetFeaturePropertyAct("CLOUD1", 1 )
- MxDev = 0
- MnDev = 0
- for i = 1 to NumPts
- PtNm = "CLOUD1:P" + CStr(i) + ":3D"
- Dev = GetReportInfo( "Cloud-to-CAD Deviation", PtNm, 3 )
- If Dev > MxDev Then
- MxDev = Dev
- End If
- If Dev < MnDev Then
- MnDev = Dev
- End If
- next
- MxDev = Round(MxDev, 4)
- MnDev = Round(MnDev, 4)
- MsgBox("Max deviation is: " + CStr(MxDev) + Chr(10) + "Min deviation is: " + CStr(MnDev))
Upon running program the High and Low (Max / Min) point are displayed in MsgBox()
See attached program for reference. Note - this program can be run on any CMM as it contains no measured features.