@RUPEEXN, please, take a look at this function:
I also suggest you save a link to the AFL Function Reference - Categorized list of functions, where you'll find all the available functions, clearly organized in categories.
For instance, in the " String manipulation (halfway down), there is the above function along with many other methods to modify text variables.
By the way, I see that you do not have the License Verified badge. I encourage you to complete the procedure ASAP (otherwise, you should only post in the Presale/Trial section of the Forum).