Hello everyone, I work with VC. There was a plug with the output of the name of an authorized user in my application. I can not parse the received response. Tell me who faced. Here is a piece of code
public void onComplete(VKResponse response) { super.onComplete(response); JSONArray resp = new JSONArray(); try { resp = response.json.getJSONArray("response"); } catch (JSONException e) { e.printStackTrace(); } JSONObject user = new JSONObject(); try { user = resp.getJSONObject(0); } catch (JSONException e) { e.printStackTrace(); } userName.setText(user.toString()); }