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)
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!