- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Can anybody help?
I have the following Python script.....
def ExportBomFile(BomFileName):
ui = None
try:
app = adsk.core.Application.get()
ui = app.userInterface
design = adsk.fusion.Design.cast(app.activeProduct)
component: adsk.fusion.Component
for idx, component in enumerate(list(design.allComponents)):
PartQuantity = "{:>4}".format(len(design.rootComponent.allOccurrencesByComponent(component)))
PartNumber = re.split(' v\d+', component.partNumber)[0]
ItemNumber = ????????
ui.messageBox(ItemNumber, 'Fusion 360', 0, 3)
except:
if ui:
ui.messageBox('Failed:\n{}'.format(traceback.format_exc()))
Does anybody know how to add the item number to the script as shown in the attached picture?
Many thanks in advance!
Darren
Solved! Go to Solution.