Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Exchange an Family

11 REPLIES 11
SOLVED
Reply
Message 1 of 12
Anonymous
844 Views, 11 Replies

Exchange an Family

Is it possible to exchange an Family by another Family ?

I have in my model a pipe with a valve from Honeywell, and I would like to replace it with one from Oventrop

 

First family - Honeywell with type TB10

Second family -  Oventrop  with type OT15

11 REPLIES 11
Message 2 of 12
AGGilliam
in reply to: Anonymous

Are you just trying to replace an instance of a family that's been placed? If so you can select the instance and set its Symbol property equal to the Family Type you want to switch it to.

Message 3 of 12
Anonymous
in reply to: AGGilliam

an instance 

Message 4 of 12
joshua.lumley
in reply to: Anonymous

Have you tried match properties? 

Capture.PNG

Message 5 of 12
RPTHOMAS108
in reply to: Anonymous

I take it from your posting history this is an API question rather than UI?

 

I'm no expert on MEP categories but the usual generic way you change one ElementType for another is by:

Element.ChangeTypeId

 

Generally if you change an ElementType from what it currently is to one from another family of the same category so be it.

 

You should review if there are any utility methods within Plumbing namespace to see if there is anything better than the above (to maintain other relationships that may be affected by such a change which I'm not aware of).

 

Message 6 of 12
Anonymous
in reply to: AGGilliam

sorry my fault 🙄, no the family is already modeled in the model, but because of the price or the customer's choice we have to change brands
so it's not an instance

Message 7 of 12
joshua.lumley
in reply to: Anonymous

Keep the family but change the manufacturer parameter so that it appears correct in schedules.

Message 8 of 12
Anonymous
in reply to: joshua.lumley

yes, but the dimensions of the valve are not the same

Message 9 of 12
RPTHOMAS108
in reply to: Anonymous

Are you encountering problems with .ChangeTypeId (Families contain types not instances).

 

Instance based dimensions should remain the same type based ones will change to what is relevant for the type.

Message 10 of 12
ahmed.errazak
in reply to: Anonymous

thank you all, it works

Message 11 of 12

May I be the accepted solution...I put in more work than RPTHOMAS108 .

 

Cheers, 

J

(not a douchebag)

Message 12 of 12

Sorry, I was so glad that it worked, that I didn't pay attention to my answer
Definitely Joshua and thanks again

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


Autodesk Design & Make Report