I am writing a macro to re-link wave linked faces, and to ensure the orientations align I am trying to measure the angle between the existing face and the new face.
I am getting an error on this line of code:
the error says:
NXOpen.NXException: Third parameter is invalid at NXOpen.MeasureManager.NewAngle(Unit units, DisplayableObject object1, EndpointType qualifier1, DisplayableObject object2, EndpointType qualifier2, Boolean minorAngle)
but I have tried all three options for the MeasureManager.EndpointType (StartPoint, None, and EndPoint). The documentation says that the qualifiers are only used for lines and edges though, so I dont' know why they affect anything when measuring two surfaces.
Any tips, or examples?
I am getting an error on this line of code:
Code:
MeasureAngle ang = workPart.MeasureManager.NewAngle((Unit)workPart.UnitCollection.FindObject("Degrees"), oldface,MeasureManager.EndpointType.StartPoint, face1, MeasureManager.EndpointType.EndPoint, false);
the error says:
NXOpen.NXException: Third parameter is invalid at NXOpen.MeasureManager.NewAngle(Unit units, DisplayableObject object1, EndpointType qualifier1, DisplayableObject object2, EndpointType qualifier2, Boolean minorAngle)
but I have tried all three options for the MeasureManager.EndpointType (StartPoint, None, and EndPoint). The documentation says that the qualifiers are only used for lines and edges though, so I dont' know why they affect anything when measuring two surfaces.
Any tips, or examples?