Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>In your server, what's the return from the client? </p> <p>When I have a problem like this, I show in the Logcat on Android what I'm sending and in the server side what I'm getting.</p> <p>I had a little problem with date too (I'm using ksoap2 and webservices), I solve my problem sending the date in the util.Date, then I use SimpleDateFormat with a pattern date in my project and convert that string to what I want.</p> <p>cya, Bertan</p> <hr> <p>Here is my code that sends to the WS:</p> <pre><code>public static byte[] send(String... param) throws SocketTimeoutException, IOException, XmlPullParserException, Exception{ //First I send the WS Name String ws = param[0]; //Second is the operationName SoapObject soap = new SoapObject(URL_SOAP, param[1]); Object retorno = null; int tamParam = param.length; //The 3 parameter for the infinity its the properties, name and the next it's the value... if (tamParam &gt; 0) { for (int i = 2; i &lt; tamParam; i++) { soap.addProperty(param[i], param[++i]); } } // create a envelope for the soap object SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11); envelope.setOutputSoapObject(soap); // create a HttpTransport to send the object soap with 15s delay MyHttpTransport httpTransport = new MyHttpTransport(URL + ws, 15000); // send the req Long tempo1 = 0l; tempo1 = System.currentTimeMillis(); httpTransport.call("", envelope); retorno = envelope.getResponse(); Long tempo2 = System.currentTimeMillis(); httpTransport.reset(); //I ever get byte[] from the WS... if (retorno != null) { byte[] bloc = Base64.decode(retorno.toString(), Base64.DEFAULT); return bloc; } else { return null; } } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload