Exception Unhandled on command to select an element in Catia

Joe Nguyen 1 Reputation point
2022-04-06T14:11:52.637+00:00

Private Sub SelTanCrv_Click(sender As Object, e As EventArgs) Handles SelTanCrv.Click
'// Select Tangent Curve
Me.Hide()

    CATIA = GetObject(, "CATIA.Application")
    CatDoc = CATIA.ActiveDocument
    CatPrt = CatDoc.Part
    ShpFac = CatPrt.HybridShapeFactory
    MySel = CatDoc.Selection

    MySel.Clear()
    '//sSelEle = ""
    sSelEle = MySel.SelectElement2(FilterGeo, "Select Tangent Curve", False)
    SCrv = MySel.Item(1).Reference

    If sSelEle = "Normal" Then
        Tan_Crv = SCrv
    End If

    Me.Show()
End Sub
Community Center | Not monitored
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.