各位高手好:
本人从txt文件读取一行,其格式为JSON字符串,想将它转成JSON对象。使用了如下方法:
jsObj = JSONObject.fromObject(lineTxt);
其中lineText的数据如下:

但是将lineText转成JSON对象后,将act解析成了JSONArray,不知道为什么,求高手指点,谢谢


本人从txt文件读取一行,其格式为JSON字符串,想将它转成JSON对象。使用了如下方法:
jsObj = JSONObject.fromObject(lineTxt);
其中lineText的数据如下:

但是将lineText转成JSON对象后,将act解析成了JSONArray,不知道为什么,求高手指点,谢谢


解决方案
60
你仔细看看,是不是json字符串里面有两个act。