Sub JobDone(Job As HttpJob)
Log("***JObDone")
If Job.Success = True Then
Log("lectura web OK")
Log(Job.GetString)
parser.Parse(StringToInputStream(Job.GetString), "Parser")
Else
Log("error de lectura web")
Log(Job.ErrorMessage)
End If
End Sub
Sub StringToInputStream (s As String) As InputStream
Dim In As InputStream
s = s.Replace("<?xml version=""1.0"" encoding=""iso-8859-1""?>", "")
s = s.Replace("<ajax-response></ajax-response>", "")
Dim data() As Byte = s.GetBytes("UTF8")
In.InitializeFromBytesArray(data, 0, data.Length)
Return In
End Sub