Herry Ng

Herry Ng

  • NA
  • 22
  • 10.1k

Android Studio, soap2 http request failed, http status : 404

Nov 3 2017 12:07 PM

Hi Im had check & recheck my KSoap2 param : Namespace, Method, SoapAction, and URL everythings looks ok but I always got error 404

The WFC service I create based on microsoft examples: https://docs.microsoft.com/en-us/dotnet/framework/wcf/getting-started-tutorial

Using the examples C# Client was success to call the WFC services, opening from browser to get xml info was success, also using WFC Test Client also success.

I already open tcp in/out port 8000 for this. Following some hints on the web Im also had change WSHttpBinding into BasicHttpBinding in my host. But when I tried to call from Android Studio 3.0 using KSoap2 ver3.6.2 its always got 404

please find both the xml data I copied from browse and the script in MainActivity.java in the attachment

To summary my

NAMESPACE ="http://tempuri.org/"; 
METHOD_NAME ="GetJunkData"; 
SOAPACTION = "http://tempuri.org/ICalculator/GetJunkData"; 
URL ="http://192.168.1.201:8000/WCFTRIAL?wsdl"; 

Im pretty sure this is correct based on the WDSL, please en-light me how Im to correct this 404 error.

 
 
 
 

Answers (3)