MoscovoPT
Member
Hi.
Would like some help with my webservice.
I've followed the video tutorial about it but got an error while connecting.
Any ideia of what could be? Have read other topics but coudn't find any answer to solve the issue.
Also add HU2_ACCEPTALL to Conditional Symbols in Build Configurations to accept all connections but no result at all too.
Error Log:
ResponseError. Reason: java.net.ConnectException: Failed to connect to /XX.XXX.XXX.XXX:80, Response:
Thanks in advance.
Would like some help with my webservice.
I've followed the video tutorial about it but got an error while connecting.
Any ideia of what could be? Have read other topics but coudn't find any answer to solve the issue.
Also add HU2_ACCEPTALL to Conditional Symbols in Build Configurations to accept all connections but no result at all too.
Error Log:
ResponseError. Reason: java.net.ConnectException: Failed to connect to /XX.XXX.XXX.XXX:80, Response:
Thanks in advance.
Webservice to Login:
#Region Project Attributes
#ApplicationLabel: TRails Portugal
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: True
#IncludeTitle: True
#End Region
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Private xui As XUI
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("Main")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub Button1_Click
Check("John", "11111")
StartActivity("Index")
End Sub
Sub Check(username As String, password As String)
Dim XML As String
XML=""
XML = XML & "<?xml version='1.0' encoding='utf-8'?>"
XML = XML & "<soap12:Envelope xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:soap12='http://www.w3.org/2003/05/soap-envelope'>"
XML = XML & "<soap:Body>"
XML = XML & "<CheckUser xmlns='http://75.119.136.162/WebServiceGeral/WebServiceGeral.asmx'>"
XML = XML & "<username>"& username &"</username>"
XML = XML & "<password>"& password &"</password>"
XML = XML & "</CheckUser>"
XML = XML & "</soap:Body>"
XML = XML & "</soap:Envelope>"
Dim ResultURL As String
Dim j As HttpJob
j.Initialize("",Me)
j.PostString("http://XX.XXX.XXX.XXX/WebServiceGeral/WebServiceGeral.asmx",XML)
j.GetRequest.SetContentType("text/xml; charset=utf-8")
j.GetRequest.SetHeader("SOAPAction","'http://XX.XXX.XXX.XXX/WebServiceGeral/WebServiceGeral.asmx/CheckUser'")
Wait For (j) JobDone(j As HttpJob)
If j.Success Then
ResultURL = j.GetString
Else
ResultURL = j.ErrorMessage
End If
j.Release
End Sub