我有这个错误:
java.io.ioException
当我执行此行
时httpTransport.call(SOAP_ACTION, envelope);
是什么原因......?有人可以帮帮我吗?
我从昨天起就一直在尝试这个,但我仍然失败了。
谢谢!
答案 0 :(得分:0)
SoapObject object=new SoapObject(NAMESPACE, METHOD_NAME);
object.addProperty("data", "123");// tis value u wil get frm web service it may change
envelope=new SoapSerializationEnvelope(SoapEnvelope.VER11);
envelope.dotNet=true;
envelope.setOutputSoapObject(object);
try {
HttpTransportSE htp=new HttpTransportSE(URL);
htp.call(SOAP_ACTION,envelope);
SoapPrimitive resultString=(SoapPrimitive) envelope.getResponse();
String server_acknowledgement=resultString.toString();
}
catch (Exception e) {
// TODO: handle exception
exceptionArise=true;
e.printStackTrace();
}