algorithmic modeling for Rhino
Tags:
hello,
is it always the case that blahblah-Ralingues # need to loose the #?
if yes i think text splitting with space would do the job.
Hi ng5 Alex,
Yes, it is the case, but since you are suggesting this workaround, do you imply that the "Replace text" does not accept masks ?
Sure would be nice to have your data to work with...? But Grasshopper text handling features are extremely limited, unfortunately. Did you consider using 'Match Text (TMatch)' instead of 'Replace Text (Rep)'?
Hi Joseph,
Well, text handling is not so limited since "Replace text" accepts "Patterns" (otherwise called "Masks" when talkling about paths) !
As David said in my post "Using ranges to define paths", there are some inconsistencies due to the development process.
I'm sure V2 will be much more flexible and coherent.
In the mean time, I havent found the formatting rules for "Replace text" !
That's someting that hopefully will be improved too : providing helpfull...help for the components.
How would you go about and perform the forementionned task with "Replace text" ?
Oliver, you must post data/code if you don't want to waste people's time.
And as noted above, 'Replace Text' does NOT accept masks, only "a specific text fragment".
wombat has a "text replace multiple" for this purpose. It does not support masks either but will at least allow you do supply a list of fragments / replacements instead of having to chain the replace component.
Consider how much more useful 'Match Text (TMatch)' (which does accept a wildcard pattern or RegEx expression) would be if only it returned an integer instead of a boolean, like JavaScript's 'indexOf()' method, for example:
Return value: The index of the first occurrence of searchValue, or -1 if not found.
Like so many conventional programming languages going all the way back to BASIC, JavaScript has a rich set of text manipulation features: indexOf(), match(), replace(), search()
I understand and I agree with your point Joseph.
I was marveling at all those other Wombat tools that I never knew about.
:)
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by