Is your string is coming from any server/webservice.
- 1 years ago
The String is Value of my CheckBoxes.
Jeon is just a string in a given format. All u need is a key and a value.
All u need is a key (name) and a value (raj).
put your data in the value and give it a key name and than u can parse your data however you want.
this is the way how you can convert string Variables to Json
JSONObject jsonBody = new JSONObject(); jsonBody.put("Title", "Android"); jsonBody.put("des", "Development"); final String requestBody = jsonBody.toString();