jestin-g
(Gabriel Jestin)
May 28, 2021, 11:17am
1
Hi,
I am having trouble trying to use Trim on a String.
The string is created from a web data scrapping.
There is only one space remaining at the end of the string, but Trim refuse to remove it.
Here is my Watch Tab:
As you can see:
Trim don’t work, but replacing all whitespace works.
The remaining whitespace seems to be a “real” whitespaces (not a “non-breaking”)
Even copy pasting directly the string and appending Trim to it dont work
Anyone have any idea where the problem might be coming from?
Thank you.
Adrian_Star
(Adrian Starukiewicz)
May 28, 2021, 12:11pm
2
Hi,
Can you show what innerHtml text looks like after examining an element in a browser page? It should be different from what is in aaname.
jestin-g
(Gabriel Jestin)
May 28, 2021, 12:48pm
3
Hi, thanks for your answer.
I am not sure what you mean. Here is what I see in UI Explorer:
I forgot to mention that I’m scrapping an entire html table via the Data Scraping Wizard
Sorry but i Cant rejust the problem.
maybe still try with TrimEnd?
jestin-g
(Gabriel Jestin)
May 28, 2021, 2:14pm
6
Hi all,
Thank you very much for all for your answers.
I may have found what is happening on my String:
The Length should be 24 but is 25.
It seems that there is a mysterious character in front of the remaining whitespace that cant be selected with mouse.
When I delete it, the whitespace is still there but Trim works.
Do you know what could be this character ?
EDIT:
Somehow it seems to be a question mark.
replacedStr=Str.Replace ( Split(Str,“)”) .last.ToString , “” )