how to remove space in the middle using c#? I have the string name="My Test String" and I need the output of the string as "MyTestString" using c#.
Please help me.
I'm calling a REST API and am receiving an XML response back. It returns a list of a workspace names, and I'm writing a quick IsExistingWorkspace() method. Since all workspaces consist of contiguous characters with no whitespace, I'm assuming the …
How can I remove all white space from the beginning and end of a string?
Like so:
"hello" returns "hello"
"hello " returns "hello"
" hello " returns "hello"
" hello world " returns "hello world"