Showing results for 
Search instead for 
Did you mean: 
Regular Visitor

Strange behaviour in string comparison


I have a really strange problem with a string comparison.


In a SharePoint list I have two columns "Title" and "Link"  that looks like this:



In a simple power app I want to compare the title with the last part of the link. Because the link is encoded I have a quite complex Substitute formula to extract the last part:





    ;"%20";" ");"%2E";".");"%2C";",");"%5F";"_");"%2D";"-");"%28";"(");"%29";")");"%26";"&");"%40";"@");"%C3%A4";"ä");"%C3%84";"Ä");"%C3%B6";"ö");"%C3%96";"Ö");"%C3%BC";"ü");"%C3%9C";"Ü");"%C3%9F";"ß"))




This gives me "ABC123". BUT now comes the strange part. I have tried different things that I put in a label:


In the first row on the left is the "Title" and on the right the converted "Link".

The second row shows the Len() of each of them. It says that the converted link has 7 characters (?)

The third row prints the first 3 characters of the converted link. Note that the blank space character " " does NOT come from the link, because I added it by hand after the colon. Like this: "First 2 characters: " & Left(converted; 3). So there is just "AB" from the link where it should be "ABC". The first character is just invisible or comes from the stars or whatever...


The last 3 rows are showing comparisons. The statements are working properly regarding the invisible first character from the row above. So "ABC123" is in "?ABC123" but not the other way round. "ABC123" is not starting or ending with "?ABC123". And "?ABC123" is also not starting with "ABC123" but is ending with this string.


One possible solution could be to shorten the converted link to the real length of the title:



Right(converted; Len(Title))



But I think this could be dangerous if the strange invisible character decides to appear at the end of the converted string.


Trim() also doesn't bing the solution, because the invisible character is no " ". It is something else. ANY IDEAS what this character could be?!?



Super User
Super User


What data type is your column ‘Link’? Is it Single line of Text or Hyperlink?

Regular Visitor

Ah I forgot to mention. Title is single line and Link is multiple lines of text.


Ok. I try to avoid using Multi line of text in my apps because they can cause some issues. If your links will fit inside a single line of text column I’d try using that and see if that corrects this behaviour?


It may also have something to do with the format of your Multi line of text column. I think formats like ‘rich text’ can cause power app issues

Helpful resources

Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,528)