Thread: KSoap Problem
View Single Post
Old 02-25-2008, 10:31 AM   #1
itahack
New Member
 
Join Date: Feb 2008
Model: 7100T
PIN: N/A
Carrier: stude
Posts: 7
Default KSoap Problem

Please Login to Remove!

public void doSOAP()
{
try
{

SoapObject rpc = new SoapObject ("http://10.1.2.39/Service1/Service1.asmx", "Login");
rpc.addProperty("sLogin","Ciro");
rpc.addProperty("sPassword","Ciro");
SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
envelope.bodyOut = rpc;
envelope.dotNet = true;
envelope.encodingStyle = SoapSerializationEnvelope.ENC;
HttpTransport ht = new HttpTransport ("http://10.1.2.39/Service1/Service1.asmx");
ht.call("http://tempuri.org/Login",envelope); // block here...
System.out.println("Res: " + envelope.toString());
System.out.println("Res: " + envelope.getResult());
}
catch (Exception e)
{
System.out.println("i am here in catch");
e.printStackTrace ();
}
}


This is a part of wsdl:
SOAP 1.1
POST /Service1/Service1.asmx HTTP/1.1
Host: 10.1.2.39
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/Login"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlnssi="http://www.w3.org/2001/XMLSchema-instance" xmlnssd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<Login xmlns="http://tempuri.org/">
<sLogin>string</sLogin>
<sPassword>string</sPassword>
</Login>
</soap:Body>
</soap:Envelope>

Simulator block on ht.call("http://tempuri.org/Login",envelope);
why??Please Help ME!!!!!!!!!!!!!
Offline   Reply With Quote