home
search
help
profile
liking the experience? our app is even better
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now  
showing results for how to convert object to jsonobject android
1String json = {"phonetype":"N95","cat":"WP"};
2
3try {
4
5    JSONObject obj = new JSONObject(json);
6
7    Log.d("My App", obj.toString());
8
9} catch (Throwable t) {
10    Log.e("My App", "Could not parse malformed JSON: \"" + json + "\"");
11}
upvote
downvote
source
queries leading to this page
android java object to jsonobjectstring to org json jsonobject androidobject to json string androidandroid convert object to jsonconvert string to jsonobject android using jsonteokenerconvert object to json in android javahow to convert json string to java object in androidandroid json object from stringcustom object to json string 2b androidconvert jsonobject to string androidandroid parse string to json objectandroid json string to jsonobjectflutter json string to objectconvert object to json androidconvert json string to json object in androidandroid json from stringandroid convert string to jsonobjectchange json string java androidhow to convert json string to object androidstring to json androidconvert string to json object androidandroid json string to objectjson string to model androidandroid object to json stringandroid java create jsonobject from stringjson to string androidandroid jsonobject from stringhow to convert jsonobject to string androidconvert string to json android studioandroid string how to convert jsonobjectconvert json to object androidconvert string to json androidconvert json to object java androidhow to convert an object to json androidandroid studio convert json to stringconvert jsonobject to string and change value androidhow to convert string to json object in androidandroid string to jsonandroid json jsonobject to stringandroid object to jsonandroid string to jsonobjectstring to jsonobject 2b androidjson string to json object android studioandroid json string to json objectandroid java object to json stringandroid java object to jsonandroid studio string to jsonjava convert string to json androidconvert string to jsonobject androidconvert json string to object in androidconvert json to object android javastring to jsonobject android studioandroid make json stringandroid convert json to objectconvert jsonobject to jsonobject androidstring to jsonobject androidstring to json in androidandroid parse json string convert string to json in androidconvert json to object in androidobject to json androidstring to json jsonobjectjson string to object android studioandroid json to objecthow to convert string to jsonobject in android javaandroid string to json example