开发者

Blackberry SOAP Webservice

What is wa开发者_运维百科y to connect to SOAP based web service from Blackberry Application. Every one is using KSoap Library. Is there no native support in Blackeberry SDK to connect to webservice.?


User JSR 172 webservices. See NetBeans / Java ME IDE/SDK docs for more information.


I am using Ksoap2 for blackberry application development when i am trying to send request through Soap then requestDump contains the value as

<v:Envelope xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:d="http://www.w3.org/2001/XMLSchema" xmlns:c="http://www.w3.org/2001/12/soap-encoding" xmlns:v="http://schemas.xmlsoap.org/soap/envelope/"><v:Header /><v:Body><DownloadRetailerMobileApp xmlns="http://www.tibco.com/schemas/WSDL/Request.xsd" id="o0" c:root="1"><RetailerMSISDN>09886069494</RetailerMSISDN><RequestType>retailerowner</RequestType></DownloadRetailerMobileApp></v:Body></v:Envelope>

and the responseDump what i am getting is as

<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Body><SOAP-ENV:Fault><faultcode xmlns="">SOAP-ENV:Server</faultcode><faultstring xmlns="">RuntimeError: Internal Server Error</faultstring><faultactor xmlns=""/></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>

and then it through an exception is

org.xmlpull.v1.xmlpullParserException: expected:END_TAG{http://schemeas.xmlsoap.org/soap/envelop/}


I use the Java Sun Wireless Toolkit 2.5.2 to generate method stubs from your webservice using your webservices' wsdl file.

You can then call your webservice using the generated files, the syntax will be something like:

WebServiceSoap_Stub stub = new WebServiceSoap_Stub();
String result = stub.webMethod(param1, param2);


I used HttpConnecttion to solve the problem I had.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜