Can I do an async XML call in Excel 2010 VBA?
问题 In my spreadsheet I have a reference to the MS XML v3 library. Here is my sample code Option Explicit Private objConn As XMLHTTP30 Public Sub HandleAsyncEvent() Debug.Print "Done" End Sub Public Function InitService(serviceUrl As String, Optional asyncMode As Boolean = True) Set objConn = New XMLHTTP30 objConn.Open "POST", serviceUrl, asyncMode objConn.setRequestHeader "Content-Type", "text/xml" objConn.onreadystatechange = HandleAsyncEvent End Function I encountered a runtime exception when