String - Removing extra spaces

Hi
I have a string variable as below
Location = " Bangalore "

I want remove spaces before and after. Could you please help me any one?
Location = “Bangalore”

@Srinivasa,

Use Location.Trim

Thanks Lakshman !. Could you please provide me full syntax?
Because i am very new to UiPath.

@Srinivasa,

Take Assign activity and then use below one
String resultString = variablestringname.Trim

2 Likes

Ok. Thank you so much Lakshman !. Got it :slight_smile:

@Srinivasa,

Please mark it above one as solution and will be helpful to others.

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