BOM Sorting VBA

BOM Sorting VBA

Anonymous
Not applicable
1,893 Views
2 Replies
Message 1 of 3

BOM Sorting VBA

Anonymous
Not applicable

Hello everyone.

I have been trying to write up a vba code that sorts the BOM - below you will find the code.

 

Public Sub StückSortBaugr()

Dim oBOMView As BOMView

Set oBOMView = ThisApplication.ActiveDocument.ComponentDefinition.BOM.BOMViews.Item("Strukturiert")

Call oBOMView.Sort("Modellnummer", True) Call oBOMView.Renumber(1, 1)

End Sub

 

 

The code however does not sort the BOM and i am not sure why - does anybody have a quick solution or the time to help me out with this matter?

 

What I would like to achieve;

 

1. Sort the boom by Part Number

2. Renumber the boom

 

and if possible

1. import the xml file that configures the layout of the boom from a specified path as the first step of the process

 

Thanks for all the help

 

Greetings

 

 

 

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

Anonymous
Not applicable
Accepted solution
0 Likes
Message 3 of 3

Anonymous
Not applicable

Ok thanks for the link

 

0 Likes