TextEncoding issue ASCII > UTF8

Can anyone tell me how in Xojo iOS to convert the following Text which contains ASCII;

Q & A

into UTF8;


Surely I don’t have to write my own search and replace for each possible ASCII?

Thanks in advance.

This is not an ASCII encoding, it’s an URL encoding.
Check iOS Wrapper from@Michel Bujardet here, I think you’ll find something.

That iOS wrapper code is 3 to 6 years old; isn’t anything available in xojo.core that can do this?

I don’t think so. I’m using it quite successfully with the latest Xojo and iOS versions.
If you remove iOS Kit (J.King), iOS Extensions (J.Leroy), iOS Wrapper (M.Bujardet) and don’t use declares you will be very limited when developing for iOS.

It’s not fine, but at least these are free and maintained when needed … so far.

Thanks, I’ll see if I can get that to work.

My bad.
I don’t think there’s a DecodeURL in iOS Wrapper but there is one in M_Text (also @Jason King), you can get it here.
Edit: that’s the one I’m using for encoding/decoding

I was just about to say I could not find it in Wrapper, but you beat me to it :slight_smile: Thanks, that will work

Too soon; M_Text has an EncodeURLComponent and a FromURLEncoded,
but the FromURLEncoded returns exactly what I put in;

Q %#038; A

instead of Q & A.

Or am I missing something @Jason King ?

M_Text is from @Kem Tekinay

I’m am not familiar with it, sorry.