Macro for Text change in extrude

Wondering if anyone knows how to access the text in sketch function
without having to edit the sketch? For eg., Link a text value to the
configuration name so that I change the config name and the text
extrude changes?. Anyone know an easy way to do this or whether it is
Reply to
Loading thread data ...
You can change the text via API. I tried this in the past and it was quite easy, but I didn't store the code for it.
Kind regards,
J.J. Zwaard
formatting link

Alex schreef:
Reply to
Man, that would be awesome if there was a way to link the text like that. I have always wanted to be able to do that as well.
However what I do now is to simply have multiple extruded text features with manually entered text, and suppress/unsuppress the appropriate features in each config. It sucks. But that all I have ever been able to come up with.
Reply to
Seth Renigar
I don't really see how this would be possible. Essentially you would need an always running program that would detect when you change a configuration name and then goes to your sketch, edits it, and updates the text used there. Seth's method sounds like the best to me.
You could also have a macro that you run which updates the text in a specific sketch to reflect the configuration name. That would be pretty easy.
Just use SketchText::Text to change the text.
Seth Renigar wrote:
Reply to
Mr. Who
Macro feature would be a way to do this, if one would like to regenerate the text on each rebuild.. You could write a macro to show user interface with selectionbox in propertymanager. The user would select the sketch text entity into the selectionbox and the feature would update the sketch text.
Reply to
Heikki Leivo
Thanks mate - Appreciate the feedback
Heikki Leivo wrote:
Reply to
I would be interested to see how easy this is as my macro understanding is not great. Thaks for the feedback though
Mr. Who wrote:
Reply to

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.