Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

GetAngleBetween Object doesn't support this property or method 1

Status
Not open for further replies.

josephv

Mechanical
Oct 1, 2002
683

Hello,

We are creating a macro to get the angle between 2 lines.
We are using the GetAngleBetween Method, but we get the following error:
Object doesn't support this property or method (Error 438)

We are using the example from the CATIA help below.

Please let us know if you have run into this and know of a fix.

Thanks,

Joseph






This example retrieves the angle between the reference1 and reference2.
Dim reference1 As Reference
Set reference1 = part1.CreateReferenceFromObject(object1) Dim reference2 As Reference
Set reference2 = part1.CreateReferenceFromObject(object1) Dim TheSPAWorkbench As Workbench
Set TheSPAWorkbench = CATIA.ActiveDocument.GetWorkbench ( "SPAWorkbench" )
Dim TheMeasurable As Measurable
Set TheMeasurable = TheSPAWorkbench.Measurable(reference1) Dim MinimumDistance As double
MinimumDistance = TheMeasurable.GetAngleBetween(reference2)
 
Replies continue below

Recommended for you


Hello,

Figured out the problem, the documentation is not correct the following line:

Set TheMeasurable = TheSPAWorkbench.Measurable(reference1)

Should read "GetMeasurable" not "Measurable"

Thank you,

Joseph
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor