Sub StartDownload(tablename As String)
If xfs.CheckConnection Then
template = File.ReadString(File.DirAssets, tablename & ".xml")
parser.Initialize
Dim job As HttpJob
job.Initialize(tablename, Me)
job.PostString(URL, BuildRequest)
job.GetRequest.SetContentType("text/xml; charset=utf-8")
job.GetRequest.SetHeader("SOAPAction", """http://tempuri.org/" & tablename & """")
Else
Activity.Finish
End If
End Sub
StartDownload("Table1")
StartDownload("Table2")
StartDownload("Table3")
StartDownload("Table4")