Skip to Content
-1

Chinese String value convert to UTF-8

Feb 23 at 09:07 AM

66

avatar image
Former Member

Hi Gurus,

how to make the Chinese characters converted to UTF-8.

URLParameterEntry.Value = "公司名称"; //Company Name

Best regards,

Leo.

API
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
avatar image
Former Member Feb 26 at 09:25 AM
0

Solution:

URLParameterEntry.Value = URL.Encode(String);
Share
10 |10000 characters needed characters left characters exceeded
Bernard Le Tourneur Feb 23 at 09:40 AM
0

Encode your value:

JAVA:

var fullName = "伯纳德";
var encodedFullName = URLEncoder.encode(fullName,"UTF-8");

JavaScript:

var fullName = "伯纳德";     
var encodedFullName = encodeURI(fullName);
Show 4 Share
10 |10000 characters needed characters left characters exceeded
Former Member

hi Bernard,

Thank you for your answer,But my programming language is not JAVA and JavaScript。

0

Can you tell me what it is then? I am sure you can use the above as long as you have a method that does URL encoding.

0
Former Member

This is the ABSL code of SAP Cloud for customer, and I just don't know the encoding and conversion method of this ABSL.

0

Given the methods I can see in the above you will definitely have an encoding capability. (ABSL does not appear to exist as a language)

0