I have a input variable that contains leading zeroes. I need to removed the leading zeroes to use as a filter into a table. I can use
s = s.replace(/^0+/, '')
to remove the leading zeroes via java script. But I cannot find out how to use this as part of a filter on a table. Any suggestions?
Thanks
Kevin
Hello Kevin,
The result is in the Regex_Replace.result variable.
You can use the regex_replace action and assign to a variable and use it in the filter.
Regards,
Leandro.
Leandro Correa wrote:
Leandro
I tried using Regex_Replace with the text string with leading zeroes, the Pattern "/^0+/ and replace string "". This does not seem to work. It is not replacing my leading zeroes. You mention using the replace. How would that work with replacing the leading zeroes? I did seen any examples using the replace with regex.
Or Just the Replace() function.
If you to convert the text var to integer using the TextToInteger() function will works too! ;)
I had everything that Erik has provided but was using the "/" in the Pattern. Once I removed the "/", it worked. Thanks everyone for providing suggestions.
Marked Erik's response as the solution. Again, thanks to everyone.
Glad to hear you solved it!