Hello,
Please, i have a Json provided from an external DB Table like that :
but when i read that with :
Thats show me into the listview some special char like : ♦ replacing the accented characters
and if i use the function (readed into the b4x forum):
Thats return something like that : \u00xx for each characters into the strings
Should i use a special B4X function to read all kind of international characters
or should i analyse that before the json creation ?
Thank you
Michel
Please, i have a Json provided from an external DB Table like that :
B4X:
[{"Id":"1","Libelle":"CONFORT ET BIEN-ÊTRE","PictureId":"2428"},
{"Id":"14","Libelle":"AIDES TECHNIQUES","PictureId":"3465"},{"Id":"40","Libelle":"MOBILITE","PictureId":"3464"},{"Id":"53","Libelle":"MATERNITE","PictureId":"3466"},
{"Id":"66","Libelle":"HYGIENE","PictureId":"3452"},{"Id":"79","Libelle":"DIAGNOSTIQUE","PictureId":"4533"},{"Id":"92","Libelle":"PROTECTION","PictureId":"4534"},
{"Id":"105","Libelle":"MATERIEL D’INJECTION","PictureId":"3469"},
{"Id":"32","Libelle":"EQUIPEMENT DE CABINET","PictureId":"4535"},
{"Id":"36","Libelle":"SOINS ET PANSEMENTS","PictureId":"3437"}]
but when i read that with :
B4X:
Dim parser As JSONParser
parser.Initialize(Job.GetString)
Dim rows As List
rows = parser.NextArray
and if i use the function (readed into the b4x forum):
B4X:
public Sub UnicodeEscape (s As String) As String
Dim sb As StringBuilder
sb.Initialize
For i = 0 To s.Length - 1
Dim u As String = Bit.ToHexString(Asc(s.CharAt(i)))
sb.Append("\u")
For i2 = 1 To 4 - u.Length
sb.Append("0")
Next
sb.Append(u)
Next
Return sb.ToString
End Sub
Should i use a special B4X function to read all kind of international characters
or should i analyse that before the json creation ?
Thank you
Michel