Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Something about Parsing JSON with QT and VS2010
dev_jiang last edited by
QByteArray enUrl = "http://mobilecdn.kugou.com/new/app/i/search.php?keyword=walking&cmd=300&pagesize=100";
QNetworkReply *reply = manager->get(QNetworkRequest(QUrl(enUrl)));
QByteArray musicJson = reply->readAll();
value =engine.evaluate("(" + QString(musicJson) + ")");
the problem is :
musicJson have data, but when I parsing, the value is empty;
do somebody have the same problem?
tucnak last edited by
There is one of my favourite libraries - QJson. It allows to work with JSON on the QVariant* level. Read, write, serialize, etc.
Project link: http://qjson.sourceforge.net/