How parse json array in qt
-
It's better to use the standard way. Anyway, you can use whatever method you like, if you know it well.
-
[quote author="dlfo" date="1375600100"]It's better to use the standard way. Anyway, you can use whatever method you like, if you know it well.[/quote]
I agree. It is always better to rely on the standard tools and API for such operations.
-
ok noted but can somebody plz point out what is wrong in the code?
thanks
-
Does anyone if there is anything wrong with this code? I can't parse all the elements out of it.
-
ok.
I got it solved myself. Actually each member inside QList<QVariant> needs to be converted into a QMap first and then separate out the key-value pairs.
Thanks guys
-
"QJsonDocument":http://qt-project.org/doc/qt-5/qjsondocument.html ?
-
I guess the thread author used this lib: http://qjson.sourceforge.net/
I think that is the best choice if you can't switch to Qt 5.