iFeature set plane rotation

iFeature set plane rotation

ewu9
Enthusiast Enthusiast
581 Views
2 Replies
Message 1 of 3

iFeature set plane rotation

ewu9
Enthusiast
Enthusiast

Hi!

I'm convinced there's an easy to access/write this parameter when placing an iFeature, but I can't seem to figure out how to change the angle of the sketch plane in iLogic. Any pointers? I've been using the code for inserting a standard iFeature from the API reference manual.

My alternative solution is to build an angle parameter into the iFeature itself

    ' Set the input.
    Dim oInput As iFeatureInput
    For Each oInput In oiFeatureDef.iFeatureInputs
        Dim oParamInput As iFeatureParameterInput
        Select Case oInput.Name
            Case "Sketch Plane"
                Dim oPlaneInput As iFeatureSketchPlaneInput
                Set oPlaneInput = oInput
                oPlaneInput.PlaneInput = oFace
            Case "Diameter"
                Set oParamInput = oInput
                oParamInput.Expression = "1 in"
            Case "Depth"
                Set oParamInput = oInput
                oParamInput.Expression = "0.5 in"
        End Select
    Next
    
    ' Create the iFeature.
    Dim oiFeature As iFeature
    Set oiFeature = oFeatures.iFeatures.Add(oiFeatureDef)

ewu9_0-1712167580841.png

 

0 Likes
Accepted solutions (1)
582 Views
2 Replies
Replies (2)
Message 2 of 3

Michael.Navara
Advisor
Advisor
Accepted solution
0 Likes
Message 3 of 3

ewu9
Enthusiast
Enthusiast

Yes, that's exactly it. Thank you!

0 Likes