Announcements
Due to scheduled maintenance, the Autodesk Community will be inaccessible from 10:00PM PDT on Oct 16th for approximately 1 hour. We appreciate your patience during this time.
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: 

Create Curtain System

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
Anonymous
668 Views, 2 Replies

Create Curtain System

I am new to Revit. I want to create a Curtain System for the selected faces. To create, I can call the method

CurtainSystem cs = document.Create.NewCurtainSystem() which takes two parameters. I can get the facearray from the user selection. But I am not knowing how to create a CurtainSystemType which is the second parameter. Is there any sample code for this?

Also, can i colour the curtain system with multiple colors (different color for each grid) ?

Thanks,

2 REPLIES 2
Message 2 of 3
aignatovich
in reply to: Anonymous

Hi!

 

You can use FilteredElementCollector to retrieve all CurtainSystemTypes or you can use doc.GetDefaultElementTypeId(ElementTypeGroup.CurtainSystemType)

 

1)

var collector = new FilteredElementCollector(doc);
var cst = collector.OfClass(typeof(CurtainSystemType)).OfType<CurtainSystemType>().FirstOrDefault(x => <your condition>);

2)

var cstId = doc.GetDefaultElementTypeId(ElementTypeGroup.CurtainSystemType);
var cst = (CurtainSystemType)doc.GetElement(cstId);
Message 3 of 3
aignatovich
in reply to: Anonymous

About your second question. You can get curtain system curtain grids, then for each curtain grid get panels, and override graphics for specific views

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

Post to forums  

Rail Community


Autodesk Design & Make Report