Remove the unwanted space at end of the string
I wrote the code for get the values from the text file. In that text file, values are entered with 'ENTER' delimiter. some of the values contains spaces at the end. I get the values with the using of text reader,i wnat to remove the unnecessary spaces from that values.
bcoz that values are email address,I used the regular expression to validate the mail address;in case of that unnecssary space occured at the end of the values.. regular expression consider that values as invalid mail address.
How to resolve this one?
pls any one know about this,share with me.......
thanks in advance!
|