Results 1 to 2 of 2

Thread: XMLHTTP Timeout

  1. #1
    Join Date
    Dec 1969

    Default XMLHTTP Timeout

    I&#039;m retreiving webpages using XMLHTTP, but I want to set my timouts, how can this be done, I have done the following:<BR><BR>Set xml = Server.CreateObject("Microsoft.XMLHTTP")<BR>xml.Ti meout=45<BR><BR>But it does not support TimeOut as a method, does anybody know what I need to do?<BR><BR>Thanks

  2. #2
    Joel N Guest

    Default RE: XMLHTTP Timeout

    I don&#039;t see anything in the docs about a timeout property.<BR><BR>I assume it will default to whatever the timeout is for a page you request in your browser that doesn&#039;t come down. Using the onreadystatechange property you can call a function when the readyState property changes and thereby know various stages of the request.<BR><BR>This JScript snippit is from the MSXML SDK 3.0 documentation which you can download from Microsoft here:<BR><BR>http://msdn.microsoft.com/downloads/default.asp?url=/downloads/sample.asp?url=/msdn-files/027/000/542/msdncompositedoc.xml&frame=true<BR><BR><BR><BR>var XmlHttp;<BR>XmlHttp = new ActiveXObject("Msxml2.XMLHTTP");<BR>XmlHttp.onread ystatechange = doHttpReadyStateChange;<BR>XmlHttp.open("GET", "http://localhost/sample.xml", true);<BR>XmlHttp.send();<BR>function doHttpReadyStateChange() {<BR>if (XmlHttp.readyState == 4) {<BR> alert("Done"); <BR>}<BR>}

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts