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.
Is it possible to set a property within a Part Configuration from Configuration Variables?
I have created a configured part studio with 2 configuration input variables: "Dia" and "Length".
I want to set the the property "Name" of the part to be a combination of a fixed text string followed by the diameter and length information.
Are there functions in OS that can be used in a Part Configuration table to convert a variable to formatted text?
I want to set the the property "Name" of the part to be a combination of a fixed text string followed by the diameter and length information.
Are there functions in OS that can be used in a Part Configuration table to convert a variable to formatted text?
0
Answers
For example, something along the lines of the C Standard Library function sprintf(). Using your example the part configuration table for the property "Name" would contain: sprintf("Cylinder_%u_%u",#Length,#Diameter).
I will investigate using your FS as a workaround.
Thanks.
I'm using this method for a configured hardware library, where the configured items populate the name of the part. Sound similar to what you're trying to do too. I think this feature should do what you want. Ping me if you get stuck.
The custom features are the official way to do this. And they work very good. onshape is built so that custom features are an integral way to use the system. If you are not using or sub-consciously labeling custom features as "not as good as integrated features" you are seriously impairing your ability to function efficiently within onshape. Custom feature only differ in one way from standard integrated ones. The person who created it was not being paid to do so(usually). I would advise you to let go and start making custom features your go to when trying to perform a task that is not immediately obvious within the standard tool set. I love watching YouTube videos of people making things like knives and hammers and creating other tools with mills and lathes. When they are done making there tool, it always seems to perform as good or better then one that could have been bought in a store. The one in the store usually doesn't fit your hand as well though.