I try to connect to the .NET WCF service in Android using kSOAP2 (v 2.1.2), but I always get a fatal exception when I try to make a service call. I am a little at a loss to track the error and cannot understand why this is happening. The code I'm using is below:
EDIT: Delete old stack traces. Thus, the first problem was that the program could not open the connection due to missing methods or libraries due to the use of vanilla kSOAP2, and not a modified library for Android (kSOAP2-Android). The second problem is the problem with the settings. In the manifest, I did not add the following setting:
I am having a problem with XMLPullParser which I need to find out.
12-23 10: 58: 06.480: ERROR / SOCKETLOG (210): add_recv_stats recv 0
12-23 10: 58: 06.710: WARN / System.err (210): org.xmlpull.v1.XmlPullParserException: unexpected type (position: END_DOCUMENT null @ 1: 0 in java.io.InputStreamReader@433fb070 )
12-23 10: 58: 06.710: WARN / System.err (210): with org.kxml2.io.KXmlParser.exception (KXmlParser.java:243)
12-23 10: 58: 06.720: WARN / System.err (210): when org.kxml2.io.KXmlParser.nextTag (KXmlParser.java:1363)
12-23 10: 58: 06.720: WARN / System.err (210): at org.ksoap2.SoapEnvelope.parse (SoapEnvelope.java:126)
12-23 10: 58: 06.720: WARN / System.err (210): at org.ksoap2.transport.Transport.parseResponse (Transport.java:63)
12-23 10: 58: 06.720: WARN / System.err (210): at org.ksoap2.transport.HttpTransportSE.call (HttpTransportSE.java:100)
12-23 10: 58: 06.730: WARN / System.err (210): with org.example.android.ValidateUser.onCreate (ValidateUser.java:68)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.Instrumentation.callActivityOnCreate (Instrumentation.java:1122)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.ActivityThread.performLaunchActivity (ActivityThread.java:2104)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2157)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.ActivityThread.access $ 1800 (ActivityThread.java:112)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.ActivityThread $ H.handleMessage (ActivityThread.java:1581)
12-23 10: 58: 06.730: WARN / System.err (210): with android.os.Handler.dispatchMessage (Handler.java:88)
12-23 10: 58: 06.730: WARN / System.err (210): with android.os.Looper.loop (Looper.java:123)
12-23 10: 58: 06.730: WARN / System.err (210): with android.app.ActivityThread.main (ActivityThread.java:3739)
12-23 10: 58: 06.730: WARN / System.err (210): with java.lang.reflect.Method.invokeNative (Native Method)
12-23 10: 58: 06.730: WARN / System.err (210): with java.lang.reflect.Method.invoke (Method.java data15)
12-23 10: 58: 06.730: WARN / System.err (210): with com.android.internal.os.ZygoteInit $ MethodAndArgsCaller.run (ZygoteInit.java:739)
12-23 10: 58: 06.730: WARN / System.err (210): when com.android.internal.os.ZygoteInit.main (ZygoteInit.java:497)
12-23 10: 58: 06.730: WARN / System.err (210): with dalvik.system.NativeStart.main (Native Method)