How to create family of parts programmatically??

Valued Contributor
Valued Contributor

Hi.

 

I need to create family of parts in existing part document. Does somebody know how to do it programmaticaly? And how to add variable that will have different value in different family members?

 

Or, maybe, somebody know how to combine two part document in one family?

 

I would appreciate any information!

 

Posted by: Walker
Post date: 6/11/2012 6:02:01 AM

1 REPLY

Re: How to create family of parts programmatically??

Valued Contributor
Valued Contributor

I think what you're looking for would be PartDocument.FamilyMembers.Add() and PartDocument.FamilyMembers.AddFamilyVariable(), but I've never tried either of those. I'd start by setting up a family the way I wanted it interactively, then writing a test program to iterate over the Items in the FamilyMembers collection and look at the properties in the debugger (or use SE Spy).

 

Hope that helps.

 

Posted by: Jay Carlton
Post date: 6/18/2012 5:28:34 PM