Hi!
I’m a complete novice when it comes to scripting. I’ve tried using ChatGPT for help, but I end up with error no matter how much it tries to help me.
I want to make a script or macro or something that allows me to export more than one geometry in Rhino as separate .stl files.
Any help is appriciated, I’ve attatched the script AI gave me that dosn’t work. Thank you.
Hi Helvetosaur!
The Basic script worked like a charm.
I feel like the only thing I might want to change is the ability to give the stl files a name and maybe setup a folder where the stl files export to. I feel like there’s possibilities to do this in the script : BatchExportSTLByObjWFixedSettingsPlus
Can you point to which line in the script is responsible for the naming and destination of the export so to speak?
Quick bakground: I make custom insoles for 3d printing. Typically there would be between 1 and 5 meshes that I would like to export as separate stl files. These should have the ordernumber for the job + L (for left side) + 001 (partnumber). The same for the right insole but changed to R for right side.
Typing the ordernumber manually through the Commandline or something is okay. I will get by just fine with the basic script, but if there’s possibilities of polishing the workflow even more that super. Thanks for your time.
/ Linus
The basic script does ask for a folder where to store the files. In the “plus” script below, I added the possibility to add a prefix name to the object numbering. It currently adds an underscore between the prefix and the number, you can eliminate that by changing this:
to this:
(or change the separator to something else…)
I also added the option to change the start number to something other than 1 (0 minimum). Let me know if this works for you.