Vous êtes sur la page 1sur 2

The Python Script Collection For Windows - Generating BOM (bill of ...

http://win32com.goermezer.de/content/view/31/291/

Home Newsflash Archive Sitemap Contact Login/Register Submit something RSS

Home Script Collection Adobe applications CAD Systems Internet Explorer Lotus Notes Microsoft Office Microsoft Project Microsoft Access Microsoft Visio MS Speech Engine OpenOffice Windows Media Player Microsoft Windows Windows Scripting Host WMI Image/Graphic Other Articles CATIA V5 Articles Microsoft COM articles

Home Script Collection CAD Systems Generating BOM (bill of material) from CATIA V5 Generating BOM (bill of material) from CATIA V5

Feedback

If the page "The Python Script Collection For Windows To test this sample you should have installed Pywin32 and start CATIA V5 before running this script. Generating BOM (bill of material) from CATIA V5" was import win32com.client useful for you, please give it a +1: catapp = win32com.client.Dispatch("CATIA.Application")
doc=catapp.ActiveDocument.Product product_count = doc.Products.Count 0 print "This example prints all Parts and subproducts of \ a CATProduct up to the 2nd level." for products in range(product_count): Comments products = products + 1 print doc.Products.Item(products).Name, ":" part_count = doc.Products.Item(products).Products.Count I tried this for outlook for parts in range(part_count): 2007 and it doesn't work, parts = parts +1 print " ", doc.Products.Item(products).Products.Item(parts).Name but python doesn't have an For a HTML-generated Bill of materialyou should better use the BOM-generation from CATIA V5: er... More... import win32com.client catapp = win32com.client.Dispatch("CATIA.Application") I never understood doc=catapp.ActiveDocument.Product doc.Product.ExtractBOM(2, "c:\BOM.html") why people don't include

Last Updated ( Friday, 20 March 2009 )

the import statements at the top of ... More... Thanks friend! ;-) Work really apprecciated from italy! More... y am I not being allowed to view more on catia scripts. More... eval('item.%s' % attribute) should be written as getattr(item, attribute) More...

Comments 0 # juju 2007-08-13 06:15 Is it possible to get the position matrix too ? Reply | Reply with quote | Quote | Report to administrator 0 # praveen 2011-05-31 14:13 y am I not being allowed to view more on catia scripts. Reply | Reply with quote | Quote | Report to administrator Refresh comments list RSS feed for comments to this post

RSS category feeds


News Articles Script examples

RSS site feeds

Login Form
Username
JComments

More related Thanks to...


Notebook Guide

Add comment

Password < Prev [ Back ] Next > Remember me Lost Password? No account yet? Register

Advertisement
Fashionez.com is a leading supplier of Wedding Dresses, Party Dresses, Men's Clothing, Women's Clothing, Cosplay Costumes, Baby & Kids

My prefered Python IDE

1 of 2

2011/10/19 05:16

The Python Script Collection For Windows - Generating BOM (bill of ...

http://win32com.goermezer.de/content/view/31/291/

My prefered Python editor is Pyscripter from MMExperts. It is not only an editor. Pyscripter is a full Python IDE including (remote) debugging, a class browser, and all other nice helpers which a full featured IDE needs.

Clothing.

Do you have a script for me ?


Do you have an interesting Python script which does some really cool thing on Windows ? Please post them to this site. It`s very simple - simply copy&paste it to this form. No login is requiered. Hint: For syntax highlighting and correct Python intendation place your code between html tags <pre> and </pre>.

My prefered web framework


My prefered web framework for developing web applications is Django. Django calls itself The web framework for perfectionists with deadlines. It is a really fast, scalable and (thanks Python) the sexiest web framework of the world. Copyright 2006 Dipl.-Ing. Mustafa Grmezer. All trademarks and registered trademarks are the property of their respective companies. All images on this pages are of the respective artists. Some of the images showing on win32com.goermezer.de are copies from other webpages/magazines. If the owners of these images insist on there copyright, please contact me and I will remove them immediately. I will accept no responisibility for the content of the listed links or the services offered by the linked sites. If you miss a backlink from one of the tools used by this CMS, please visit the disclaimer.

2 of 2

2011/10/19 05:16

Vous aimerez peut-être aussi