Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error on creating reference

zhonyang

Structural
Jul 27, 2022
9
ES
Hello all,

Here is my code:

Dim hybridShapeLineNormal1 As HybridShapeLineNormal
Set hybridShapeLineNormal1 = hybridShapeFactory1.AddNewLineNormal(reference3, reference1, -5.000000, 5.000000, False)
Set reference4 = Catia.activedocument.part.CreateReferenceFromGeometry(hybridShapeLineNormal1)
Set TheMeasurable = TheSPAWorkbench.GetMeasurable(reference1)
MinimumDistance = TheMeasurable.GetMinimumDistance(reference4) - error occur on this line, I think sth wrong on reference4

Could anybody guide how to create a reference on the object existed in background? I don't want this line appear in my model, it wastes time.
 
Replies continue below

Recommended for you

Part and Inventory Search

Sponsor

Top