Hallo,
habe gerade auf die schnelle nur VB und XMLHTTP gefunden:
Public Function sendXMLToServer(xmlDoc As DOMDocument30, DataxmlDoc As MSXML2.DOMDocument30) As Boolean
Dim xmlHttpReq As MSXML2.XMLHTTP30
sendXMLToServer = False
On Error GoTo SendXMLError
Set xmlHttpReq = New MSXML2.XMLHTTP30
xmlHttpReq.open "post", serverpath & "/[PfadzurAnwendung]/[Anwendung]", False
xmlHttpReq.setRequestHeader "Content-type", "text/xml"
xmlHttpReq.send xmlDoc.xml 'string/array to send
If xmlHttpReq.Status <> 200 Then
ErrorMessage = "Die Verbindung zum Server ist fehlgeschlagen! (Http Request POST " & xmlHttpReq.Status & ")"
Set xmlHttpReq = Nothing
Exit Function
End If
Set DataxmlDoc = New MSXML2.DOMDocument30
DataxmlDoc.async = False
'MsgBox xmlHttpReq.responseText
If DataxmlDoc.loadXML(xmlHttpReq.responseText) = False Then
ErrorMessage = "Es ist ein Fehler beim Laden der Daten aufgetreten!"
Set xmlHttpReq = Nothing
Exit Function
End If
If DataxmlDoc.documentElement.baseName = "error" Then
ErrorMessage = DataxmlDoc.documentElement.firstChild.Text
Set xmlHttpReq = Nothing
Exit Function
End If
sendXMLToServer = True
Set xmlHttpReq = Nothing
Exit Function
SendXMLError:
ErrorMessage = "Die Datei konnte nicht an den Server gesendet werden!"
Set xmlHttpReq = Nothing
End Function
Gruß,
LeKuchen