通过WEBAPI调用k3Cloud接口,返回有乱码
金蝶云社区-135xxxx7752
135xxxx7752
0人赞赏了该文章 1,874次浏览 未经作者许可,禁止转载编辑于2016年04月18日 11:48:14

将返回的字符串按utf-8转码后,还是出现了乱码,求解决

转码前
{"Result":{"ResponseStatus":{"ErrorCode":500,"IsSuccess":false,"Errors":[{"FieldName":"","Message":"绯荤粺鍙傛暟涓缃簡鍙厑璁稿綍鍏ユ湭鏉ユ湡闂存暟涓�鐨勫嚟璇侊紒"},{"FieldName":"","Message":"绗�琛屽垎褰曪細[閾惰瀛樻]鏄摱琛岀鐩紝 蹇呴』褰曞叆缁撶畻鏂瑰紡鍜岀粨绠楀彿锛�}],"SuccessEntitys":[]},"Id":""}}

按utf-8转码后new String(line.getBytes(), "utf-8")
{"Result":{"ResponseStatus":{"ErrorCode":500,"IsSuccess":false,"Errors":[{"FieldName":"","Message":"系统参数中设置了只允许录入未来期间数�?的凭证!"},{"FieldName":"","Message":"�?行分录:[银行存款]是银行科目, 必须录入结算方式和结算号�?}],"SuccessEntitys":[]},"Id":""}}