0

I want to replace all spaces in a line before a text comes, for example I have the following text:

@"  Hello\n   world"

and i want it to look like this:

@"Hello\nworld"

How can you do this for every line?

wintersan
  • 129
  • 1
  • 2
  • 9

1 Answers1

0

You need to trim white spaces from string. Check this thread. There is a solution.

Community
  • 1
  • 1
mert
  • 1,902
  • 2
  • 21
  • 41