Change pipe diamter before create using api

Change pipe diamter before create using api

Anonymous
Not applicable
1,591 Views
3 Replies
Message 1 of 4

Change pipe diamter before create using api

Anonymous
Not applicable

I want to change the pipe diameter value in red rectangle

 

PIPE_DIA.png

 

help me!

0 Likes
1,592 Views
3 Replies
Replies (3)
Message 2 of 4

Charles.Piro
Advisor
Advisor

Hi,

 

the diameter is a parameter of the pipe. Sample :

 

 

double dblnewValue = 0.328084; //Value for 100mm

using (Transaction trans = new Transaction(doc))
 {
   trans.Start("modify Diameter");

    _pipe.get_Parameter(BuiltInParameter.RBS_PIPE_DIAMETER_PARAM).Set(dblnewValue);

     trans.Commit();

 }

 

Smiley Wink

 



PIRO Charles
Developer

PIRO CIE
Linkedin


Message 3 of 4

franciscopossetto
Advocate
Advocate

Did you find Any solution for this question?

Github:
https://github.com/franpossetto
0 Likes
Message 4 of 4

jeremy_tammik
Alumni
Alumni

This discussion is continued in a later thread:

 

https://forums.autodesk.com/t5/revit-api-forum/set-pipe-diameter-before-select-the-pipetype/m-p/1009... 

  

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes