Get List of Available Styles From Style Manager

Get List of Available Styles From Style Manager

Anonymous
Not applicable
758 Views
2 Replies
Message 1 of 3

Get List of Available Styles From Style Manager

Anonymous
Not applicable

I am working on a drawing rule that lets the user change the style of all the balloons in a drawing sheet based on the available balloon styles as selected from a drop down menu. I need to get a list of the available balloon styles available as shown in the Styles Editor Window (pictured below), but I can only seem to get the name of the active style.

 

Is there a way to obtain the names of the available styles in a multi-value parameter or some other form?

 

Available Balloon Styles I would like to obtain the names of within an iLogic RuleAvailable Balloon Styles I would like to obtain the names of within an iLogic Rule

 

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

JamieVJohnson2
Collaborator
Collaborator
Accepted solution

Is there a way to obtain the names of the available styles in a multi-value parameter or some other form?

            GetInventorApplication()
            Dim idwDoc As Inventor.DrawingDocument = invApp.ActiveDocument
            Dim dsm As DrawingStylesManager = idwDoc.StylesManager
            Dim lstBalloonNames As New List(Of String)
            For Each bStyle As BalloonStyle In dsm.BalloonStyles
                lstBalloonNames.Add(bStyle.Name)
            Next

Here we assume an outside residing code of VB.Net, for iLogic, the first line won't be necessary, and invApp = ThisApplication

 

 

Jamie Johnson : Owner / Sisu Lissom, LLC https://sisulissom.com/
Message 3 of 3

Anonymous
Not applicable

Thank you! This worked perfectly

0 Likes