AnsweredAssumed Answered

Macro: Generate BOM, Export to Excel

Question asked by Andy Gerber on Oct 3, 2013
Latest reply on Oct 15, 2014 by Trevor Wood

Hey folks, I'm trying to open an assembly, run a macro, and have it spit out a BOM to an excel file.

 

I'm trying to get the macro to use either a "select all" or "use current selection" function to generate the BOM from, but I can't seem to get either to work.

 

Ideally, I would open an assembly (WhateverName.sldasm), and then run a macro to create a BOM table using a pre-defined template (ExcelBom.sldbomtbt), and save it somewhere as an Excel file with the same filename as the assembly (WhateverName.xls).

 

I'm not super experienced writing macros, so I've been using the macro-record feature and some editor tweaking to try and get through this, but I'm hitting roadblocks when it comes to generating the tables. From poking around, I haven't seen any macros that actually generate a table, so maybe this is a limitation of the tool?

 

Would really appreciate any help, suggestions, or references for me to check out. Thanks!

Outcomes