New schedule/type pipe settings

Gilles.Lagrilliere
Advocate
Advocate

New schedule/type pipe settings

Gilles.Lagrilliere
Advocate
Advocate

Hello everyone,

 

How can I create a new schedule/type for a new segment in the pipe settings?

GillesLagrilliere_0-1638866490872.png

 

0 Likes
Reply
Accepted solutions (1)
450 Views
2 Replies
Replies (2)

RPTHOMAS108
Mentor
Mentor
Accepted solution

PipeScheduleType.Create
PipeSegment.Create

 

Seems to be the way.

0 Likes

naveen.kumar.t
Autodesk Support
Autodesk Support

Hi @Gilles.Lagrilliere ,

 

Yes, what @RPTHOMAS108  mentioned was correct. If you are looking for the sample code, Here is the sample code

 

 

Pipe p;
PipeSegment seg = p.PipeSegment;
ICollection<MEPSize> sizeSet=seg.GetSizes();

ElementId MaterialId =Material.Create(doc, "my Material");             
PipeScheduleType type=PipeScheduleType.Create(doc, "My PipeSchedule type");  
ElementId  ScheduleId = type.GetTypeId();       
PipeSegment pipeSeg = PipeSegment.Create(doc, MaterialId, ScheduleId, sizeSet);
pipeSeg.Name = "My PipeSegment Name";

 

 

 


Naveen Kumar T
Developer Technical Services
Autodesk Developer Network

0 Likes