I have SW drawings having multiple sheets and each sheet is having atleast 4 to 5 views of assembly. I want all these views linked to BOM for which I have to right click each view, go into its properties and check mark the option where it says " Link to BOM" .

If I can generate a macro which picks all the views in all sheet in one go and link to BOM.

'Get BOM name Do While Not swFeat Is Nothing If "BomFeat" = swFeat.GetTypeName Then Set swBomFeat = swFeat.GetSpecificFeature2 Set swBOM = swBomFeat.GetFeature sBOMname = swBOM.Name Exit Do End If Set swFeat = swFeat.GetNextFeature Loop

HI, thanks for this macro. It really works, but it is not automatically linking the views to the BOM as I have to run the macro again and again to link the views to the BOM whenever I insert the new BOM in the drawing sheet. Can you please modify this program so that once I run the macro it automatically links the view to the BOM every time when I insert the new BOM.

Can anyone confirm that this only works for views where the referenced component of that view is the component of which the linked BOM is based, i.e. this code does not link views of the individual components to the BOM, even though you can right click on them and 'manually' check the box to link them to the specific BOM..?