Count amount of part numbers in SolidEdge DFT



The issue I have here is I am not quite sure how to access parts of a Solid Edge Draft Document. I attached a PNG (dft_partNo.PNG) that demonstrates what I would like to "count".


The issue here is, I am looking to create a tree view for a particular draft document - which includes all of it's children needed to create said part.




I choose the file:



Which opens the document seen on the attached picture.


It's first four children are:






So these are part of the initial [b]170-0832-00X[/b] draft document. How would I go about getting the count result: 4?


I am using Visual Basic 2010 with Windows 7 64bit.



Thank you for your help, if more information is needed I will be glad to support you with it!



Posted by: Alex
Post date: 12/10/2012 7:40:08 AM


Count amount of part numbers in SolidEdge DFT

It appears that the parts list object doesn't have a .Count property which it should. You may be able to get the parent and then query the parent. It would still be a good idea to send in an ER to try and get them to add a .Count property to the parts list object.


Posted by: Terry Tyson
Post date: 12/10/2012 8:02:24 AM

Count amount of part numbers in SolidEdge DFT

Alex, no need to apologize.


Let me just pop out a little solution that may work for you. I used this basic concept to auto-dimension drawings. It's somewhat involved and you shouldn't have to go to so much trouble but it should work.


The drawing view object simply contains all the lines that make up the view. Each line has a .Parent property. Create a List(Of T) and then start reading through the lines one at a time and look at the parent. If the parent doesn't exist in your List() add it, if it does, ignore it and go on to the next line. Once this process has run, your List().Count will tell you how many parts are in the view.


Posted by: Terry Tyson
Post date: 12/10/2012 11:22:49 AM