iLogic to Set Pre-Defined Set Flat Pattern Orientation

iLogic to Set Pre-Defined Set Flat Pattern Orientation

KsweenyQ4WCU
Participant Participant
350 Views
2 Replies
Message 1 of 3

iLogic to Set Pre-Defined Set Flat Pattern Orientation

KsweenyQ4WCU
Participant
Participant

In "Edit Flat Pattern Definition", I can create a list of orientations to select between, but it is a manual process. Is there a way to do this with iLogic? It seems like all the orientation-related functions are to get read-only properties, but I need to be able to write which I want. Any help would be greatly appreciated.

KsweenyQ4WCU_0-1678910492041.png

 

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

JelteDeJong
Mentor
Mentor
Accepted solution

You can activate the orientation like this.

Dim doc As PartDocument = ThisDoc.Document
Dim def As SheetMetalComponentDefinition = doc.ComponentDefinition

For Each orientation As FlatPatternOrientation In def.FlatPattern.FlatPatternOrientations
    If (orientation.Name = "A-C") Then
        orientation.Activate()
    End If
Next

 

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

Message 3 of 3

KsweenyQ4WCU
Participant
Participant

Hi, this does exactly what I want it to do, thank you

0 Likes