-
-
Notifications
You must be signed in to change notification settings - Fork 46
No mapping for the Unicode character exists in the target multi byte code page
Mobius One edited this page Apr 19, 2022
·
3 revisions
Famoso erro dos Delphis novos referentes a acentuação de strings. As formas existentes para resolver o problema são:
- Utilizar
escape_chars(string)
no servidor antes de devolver oResult
pro cliente e, no cliente, utilizarunescape_chars(string)
pra decodificar o texto. - Ao usar seu
JSONObject
,JSONArray
ouJSONValue
, capturar o texto dele como.ToJSON
no servidor e no cliente e não como.ToString
. - Converter o texto pra UTF8 com o
TEncoding.UTF8
no servidor e no cliente usarUTF8Decode(string)
.