hexagon logo

VBScript to capture xyzijk and devation of a surface measurement

Hi everyone,

I'm newish to PC-DMIS, I’m looking for a way to export dimension data from a constructed feature set and report the XYZ and deviation from the theoretical from the points taken from the cad model to a text file after every run.

I’ve manage to work out how to report the point data but I’m stuck on how to report the feature set any ideas?
  • You want to export the dimension data or the actual hit information?
  • Dimension Data I’m after (the reported Deviation)... basically I've constructed individual points grouped them as a feature and reported in PC-DMIS which is great until some has asked me for the data so was looking for an output of the raw data X Y Z and the deviation of the points in the feature.

    Thanks for the reply, I've tried to download the zip keeps telling me to log in throws me into a loop, might be works internet blocking it. Will try at home.
  • The points you grouped, are they an actual feature, eg a hole or slot, or are they an amalgam of random surface points?

    By report the set, you mean the deviation of each individual point, yeah? If so, either report each point as a location dimension with XYZT, or otherwise, create generic points using the set data hits as your numbers and report from there. Personally, I would go with the first option, but here is how you work it out the other way:

    With a set named SET_C, and then change the [1] to [2], [3] etc for the number of points in the set.

    GENERIC_PNT =GENERIC/POINT,DEPENDENT,CARTESIAN,$
    NOM/XYZ,<SET_C.HIT[1].TX,SET_C.HIT[1].TY,SET_C.HIT[1].TZ>,$
    MEAS/XYZ,<SET_C.HIT[1].X,SET_C.HIT[1].Y,SET_C.HIT[1].Z>$
    NOM/IJK,<SET_C.HIT[1].TI,SET_C.HIT[1].TJ,SET_C.HIT[1].TK>$
    MEAS/IJK,<SET_C.HIT[1].I,SET_C.HIT[1].J,SET_C.HIT[1].K>
  • If you turn on textual analysis for the profile dimension it will provide a list of the XYZIJK and deviation of every point in the set. If you are using .rtf format for your report you can just copy these right out of the report and paste into excel. If you must have the data in a separate text file the easiest method is to create a cloud of points feature (assuming you have this function available in your license) and then create a cloud of point Export operator and set the file type to .XYZ. This will export the XYZIJK values for each point in the COP feature to a file. It will not give you deviation. You can also write a script to pull the data and write it to a file. This is the most work on your end but gives you complete flexibility as to the formatting, the data that you pull out, how the file is named and saved, etc.