Private Function HttpGet(ByVal URL As String) As String
On Error GoTo errormsg
Dim HTTP As MSXML2.ServerXMLHTTP
Set HTTP = CreateObject("Msxml2.ServerXMLHTTP.6.0")
HTTP.Open "GET", URL, False
HTTP.send
If HTTP.Status = 200 Then
HttpGet = HTTP.responseText
Else
HttpGet = "推送出错:" & HTTP.Status
End If
errormsg:
HttpGet = "推送出错,请重试!"
End Function
POST
Function HttpPost(Url As String, PostMsg As String) As String
On Error GoTo er
Dim XMLHTTP As Object
Set XMLHTTP = CreateObject("Msxml2.XMLHTTP")
If Not IsObject(XMLHTTP) Then
Set XMLHTTP = CreateObject("Microsoft.XMLHTTP")
If Not IsObject(XMLHTTP)