Spanish Cargar Dataset de webservice ASMX

Hola.
Tengo un webservice en net asmx que regresa un dataset.
Funciona bien en el navegador y regresa un XML con el resultado de mi consulta.

Deseo ese dataset utilizarlo en B4A y desplegar los datos en unas cajas de texto
He buscado y he llegado hasta este punto donde si entra al jobdone pero hasta ahí me quedé sin ningún error hasta el momento pero si me faltan los datos del dataset
¿Alguna ayuda en mi programación.?
Ya solo me falta resolver este detalle para seguir con mi aplicación.


B4X:
#Region  Project Attributes 
    #ApplicationLabel: DatosFinal
    #VersionCode: 1
    #VersionName: 
    'SupportedOrientations possible values: unspecified, landscape or portrait.
    #SupportedOrientations: unspecified
    #CanInstallToExternalStorage: False
#End Region

#Region  Activity Attributes 
    #FullScreen: False
    #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.
    Dim xmlParser As SaxParser
End Sub

Sub Activity_Create(FirstTime As Boolean)
    Activity.LoadLayout("Layout")
End Sub

Sub Activity_Resume

End Sub

Sub Activity_Pause (UserClosed As Boolean)

End Sub

Sub Button1_Click
    ConsumirServiciPOST("solo")
End Sub
Sub ConsumirServiciPOST(Solo As String)
    Dim job1 As HttpJob
    Dim XML As String
        
    XML = "<?xml version='1.0' encoding='utf-8'?><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'><soap12:Body><LeeDatos xmlns='http://192.168.0.7/CargaDatos/' /></soap12:Body></soap12:Envelope>"
    job1.Initialize("JOBSOAP", Me)
    job1.PostString ("http://192.168.0.7/CargaDatos/WebService1.asmx", XML)
    job1.GetRequest.SetContentType("application/soap+xml")
End Sub

Sub JobDone (Job As HttpJob)
    If Job.Success Then
        Select Job.JobName
            Case "JOBSOAP"
                Dim Res As String
                Dim ResIS As InputStream
                Res = Job.GetString
                ResIS = Job.GetInputStream
                'Dim wsTable As String = CommonFuncs.xmlGetTagContent(Res,"GetDataSetResult")
                'xmlParser.Parse(ResIS,"xmlParserSub")
                'ResIS.Close 'Close the inputstream
        End Select
    End If
    Job.Release ' Release the job
End Sub

'Sub xmlParserSub_EndElement (Uri AsString, Name As String, Text As StringBuilder)
'If xmlParser.Parents.IndexOf("GetDataSetResult") > -1 Then
    ''do your additional parsing here..
'End If
'End Sub
 

TILogistic

Expert
Licensed User
Longtime User
Este WService es método POST o GET???

Insisto:

Cuando pruebas tu URL en un navegador web te entrega los detalle de tu Web Service.

Detalle de:

SOAP 1.1
SOAP 1.2
HTTP GET
HTTP POST
 

TILogistic

Expert
Licensed User
Longtime User
ejemplo:

1617346583426.png
 

josejad

Expert
Licensed User
Longtime User
Recuerda también que NO deberías tener una sub Jobdone en tu código, deberías usar Wait For.
 

TILogistic

Expert
Licensed User
Longtime User
Recuerda también que NO deberías tener una sub Jobdone en tu código, deberías usar Wait For.
 
Recuerda también que NO deberías tener una sub Jobdone en tu código, deberías usar Wait For.

Gracias por tu tiempo.
Ahorita estoy ahora si que copy paste de ejemplos que encuentro. En cuanto me funcione alguno de la forma que sea, entonces lo depuraré u optimizaré ya que apenas me inicio en B4A. Si analizé el código que me enviaste para otra pregunta y más o menos entendí lo que te refieres.
 

TILogistic

Expert
Licensed User
Longtime User
Gracias por tu tiempo.
Agrego imagen de lo que comentas
estimado,

No veo la llamada GET ( HTTP GET ) dentro de las imagenes.

He visto su WS y la llamada LeeDatos es un metodo GET.

Si desea ayuda publique la imagen del HTTP GET, para indicar como se llaman a estos métodos.

Saludos.
 
Top