Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Custom feature - Set RAL Color
brooke_spreen
Member, Developers Posts: 115 ✭✭✭
Hi folks, I've put together a quick feature for setting colors based on standard RAL values -
Bodies and faces are selected separately. Checking the "Override faces" box will ensure that all faces of the body, including those where a color has been previously applied, will be changed to the selected color.
The document (link) should be public/sharable/copyable/etc.
Happy scripting
Design Engineer | Anerdgy AG
Tagged:
2
Comments
Hope you don't mind, I ended up "borrowing" a bunch of your code to add these to a "company colors" feature I created a while back.
I really like how I am 100% not a programmer and I only very vaguely understand what I'm doing but because Featurescript is simple enough I was able to figure what I needed to copy (and where to paste it) to get it to integrate with what I already had (my feature starts with a drop down of "types" of colors).
The most amazing part is that it took me about 5min and it worked perfectly on the first try after hitting commit!
BOOM!
Boom indeed!
@brooke_spreen
Thanks for sharing this! I've not worked with RAL colors before, but if I do, I may end up adding it to my Part Color feature as well. If so I'll definitely credit you in the code.
Learn more about the Gospel of Christ ( Here )
CADSharp - We make custom features and integrated Onshape apps! cadsharp.com/featurescripts 💎
Maybe that means something in another language.