Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

This is not an easy job. It requires too much code and that's why I don't do it for you. But few suggestions:

 

1) For replacing components you can use ComponentOccurrence.Replace Method which allows you to replace all occurrences at the one level. You need to call this on every sub-assembly.

 

2) How to obtain info about content center part. You can read some useful info from iProperties set: Content Library Component Properties {B9600981-DEE8-4547-8D7C-E525B3A1727A} where are information which allows you to identify the ContentFamily and ContentRow. This is important when you look for content center source.

 

3) How to get ContentFamily. You can use the method ContentCenter.GetContentObject Method. As the first argument you need to pass string which looks like "v3#<FamilyId>#" where <FamilyId> is the value of FamilyId iProperty from property set mentioned above. See ContentIdentifier property of ContentFamily. In this family you need to look for appropriate ContentRow with specified PartNumber.

 

 4) Ensure the content center model. Use ContentFamily.CreateMember Method to create/update appropriate model from content center. This method returns the file name of the model which can be used in replace method mentioned above.

 

 

I hope it helps. :grinning_face: