Hi Erel,
I tried to do this, but I could not do this whit HttpUtils2. I'm traying to do something like this (php):
<?php
include("lib/nusoap.php");
$client = new nusoap_client('192.168.169.135:8080/WebApplication1/NewWebService?wsdl','wsdl');
$err = $client->getError();
if ($err) {
echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$param = array('name'=>'Pepe'); // se construye un array con la lista de parametros
$result = $client->call('hello',$param); //se manda a llamar la funcion hello y se le pasa el listado de parametros
if ($client->fault) {
echo '<h2>Fault</h2><pre>';
print_r($result);
echo '</pre>';
} else {
// Check for errors
$err = $client->getError();
if ($err) {
// Display the error
echo '<h2>Error</h2><pre>' . $err . '</pre>';
} else {
// Display the result
echo '<h2>Result</h2><pre>';
print_r($result);
echo '</pre>';
}
}
?>
I read android posts, I found that I need something like this:
try {
// Modelo el request
SoapObject request = new SoapObject(namespace, Metodo);
request.addProperty("Param", "valor"); // Paso parametros al WS
// Modelo el Sobre
SoapSerializationEnvelope sobre = new SoapSerializationEnvelope(SoapEnvelope.VER11);
sobre.dotNet = true;
sobre.setOutputSoapObject(request);
// Modelo el transporte
HttpTransportSE transporte = new HttpTransportSE(url);
// Llamada
transporte.call(accionSoap, sobre);
// Resultado
SoapPrimitive resultado = (SoapPrimitive) sobre.getResponse();
Log.i("Resultado", resultado.toString());
} catch (Exception e) {
Log.e("ERROR", e.getMessage());
}
Some example or idea to do this?
Thanks