I'mtryingtogetagetResponse
return.IcanseethereturnwithSystem.out.println
,butIcannotgetthesamereturninsidetheapplication.
HttpURLConnectionconexao=(HttpURLConnection)url.openConnection();conexao.setDoOutput(true);BufferedReaderin=newBufferedReader(newInputStreamReader(conexao.getInputStream()));StringinputLine="";
while ((inputLine = in.readLine()) != null)
System.out.println(inputLine);
lblStatus.setText(inputLine);
String respostaenvio = SomenteNumeros(inputLine);
double resposta = Double.parseDouble(respostaenvio);
if(resposta > 100000){
System.out.println("Enviado");
}else{
System.out.println("Não Enviado");
}
in.close();
conexao.disconnect();
}
Can you help me figure out what's wrong?
I need the replyback information to determine whether or not an SMS was sent.
In the line System.out.println(inputLine);
it prints exactly the code I need, but when I try to print this same code in JOptionPane
, for example, it will not.