2012-03-06 48 views
0

HIII一切,我得到的
「Microsoft.SharePoint.SoapServer.SoapServerException的SOAPFault SoapServer的錯誤字符串

我的代碼肥皂故障異常類型 SoapObject soapRequest =新SoapObject空間(namespace,方法名);

//soapRequest.addProperty("GetListResult", "TEST"); 

    SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapSerializationEnvelope.VER11); 

    envelope.dotNet=true; 
    envelope.setOutputSoapObject(soapRequest); 

    HttpTransportSE transport = new HttpTransportSE(url); 


    //AndroidHttpTransport httpTransport; 


    try { 

     System.out.println("calling service"); 
     transport.call(SOAP_ACTION,envelope); 

     System.out.println("calling complete getting result"); 


     //SoapObject soapResult = (SoapObject) envelope.bodyIn; 


     System.out.println("soap result is "+envelope.getResponse()); 

    } catch (IOException e) { 



     System.out.println("IOExceptio"); 
     e.printStackTrace(); 
    } catch (XmlPullParserException e) { 
     // TODO Auto-generated catch block 

     System.out.println("XmlPullParserException"); 

     e.printStackTrace(); 
    } 

在此先感謝!

回答

0

如果您遇到SoapFault,問題出在服務器上,而不是在Android上。使用調試設置和requestdump驗證Android創建的請求,並使用SoapUi等工具對其進行測試。然後在服務器上調試問題。

+0

因爲我是新來的android我不知道如何做到這一點,你可以幫助我更多? – 2012-03-06 06:00:19

+0

閱讀wiki的ksaop2 android網站。我把它記錄在那裏。 – 2012-03-06 06:02:35