I am trying to write an add-in for MS Word. Is it possible for MS Word add-in to listen on specific ports and to receive / receive http requests / responses? Will there be a firewall between an application running MS Word and Word?
An Office AddIn is a firewall issue (without using the Windows Firewall in its default configuration) Can request, but this firewall can not talk without triggering issues.
If you are living outside the Word you are requesting to do a service inside the service that can face firewall problems while listening on the service port.
By default, Windows Firewall is included with all versions of Windows XP SP2 or later.
Additionally,
function getrateCBR (date as dDate) as string dim sUrlRequest, intTry as integer, _ object dim oResponse strRsponse Set the object as string dim oXMLHTTP as URL set sUrlRequest = _ "http://www.cbr.ru/ script / XML_dynamic.asp? Date_req1 =" for the request of oResponse = CreateObject ("MSXML2.DOMDocument") _ & Amp; Format (DDT, "DDMMAIII") _ & amp; "& Amp; date_req2 =" & amp; Format (DDT, "DDMMAIII") _ & amp; "& VAL_NM_RQ =" & amp; Try to get the "R01235" response, 10 enters tries = 1 interval & gt; 10 set oXMLHTTP = CreateObject ("MSXML2.XMLHTTP") OXMLHTTP.Open "GET", sUrlRequest, False oXMLHTTP.send if OXILETTTP.Status = 200 then ORPSPSO.loadXML (OXMHHTP feedback text) then eliminate _expressed text if the OxxLHTML Do not set _OXMLHTTP = nothing DoEvents intTry = intTry + 1 loop no oXMLHTTP is nothing oxMLHTTP.abort :: if nothing oXMLHTTP.abort _ set oXMLHTTP = nothing is intTry & lt; = 10 then getRateCBR = Middle $ (oResponse.Text, 3) ends if not oResponse is nothing then then oResponse.abort: _ set oResponse = nothing end function By example
No comments:
Post a Comment