How to trim a number in a string variable?

Hi all,
I need to trim a number in a string variable, for example “1001528” and get “1” and “001528”, is this possible?
i tried using the method split but it separate word by word in a string, and i need trim just the first number.
thanks you so much.

Hi,
You might use Substring method

image

1 Like

Try this

strVariable.substring(0,1) for the “1”
than
strVariable.substring(1) for the rest string

2 Likes

@J0ska @syedabidraza thank you so much guys, that is the solution. :heart:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.