Read Status code
<pre><code>conn = (HttpURLConnection) connectURL.openConnection();
conn.setDoInput(true);
conn.setDoOutput(true);
conn.setUseCaches(false);
conn.setRequestMethod("POST");
conn.connect();
int code = conn.getResponseCode();
</code></pre>

<p>I have successfully established a connection. I am trying to pass the information over the internet.When the url is opened via browser I am getting response as</p>

<pre><code>{"status":"0","responseCode":"1001","response":"Wrong Settings."}
</code></pre>

<p>For correct status is returned as 1.</p>

<p>Is there any method where I can get the status only.I have been trying the following methods but every time I am getting code (below is code snippet) as -1 irrespect of status code when I am verifying manually via browser</p>
