Create Volume Piping Automatically

Hello everyone, I'm talking to the Solidworks specialists:

 

I would like to be able to create a pipe automatically from a 3D sketch:

 

1) I create a 3D sketch. 
2) I run a macro that asks me for the desired pipe diameter (thin extrud). 
3) This macro creates a pipe on the right segments, and adds bends in the corners and T's at the intersections according to the diameter entered at the beginning of the manipulation...  
4) I get 1 file per pipe (very important) per elbow and per T with precise names (example: Pipe 1 - PROJECT NAME.sldprt)

Does anyone have any idea how I can get started? 

Thank you very soon!

 

A beginning of an answer here: https://forum.solidworks.com/thread/40404

What you describe is exactly what I understand to be the Solidworks Routing module.

Want to be able to do this kind of thing by going through a macro instead of this add-in?

Hello

 

For two reasons:

 

1) I don't have the Rooting add-in

2) I would absolutely like "classic" extruded volumes with 1 file per tube and per elbow & T.

 

It will save me a lot of time, especially if I can create the pipes in a complex assembly.

 

Thank you

Hello

 

How familiar are you with APIs?

 

A good start is to record the macro when you do the manipulations by hand, to then observe the code and adapt it to your application!

 

Right-click on a toolbar > Macro > Save button.

 

What you can do is start recording the macro when you've already selected your sketch, so you can launch your macro every time with the sketch already selected (because selecting a sketch is a bit tedious).

 

After that, it will probably take a little (a lot) of adaptation for it to work properly!

 

Good luck!

1 Like

I don't know it at all! And the macro that is in the link I gave a little above seems "compiled", I opened it in a notepad and I have weird symbols.

 

Well done for the action of recording the actions done!

 

Thanks again, in any case if anyone has additional ideas I'm interested.

 

See you soon;)

1 Like