quote:
Originally posted by Matti
You should only use the responseText property when (xmlhttp.readyState == 4) and (xmlhttp.status == 200). Try that and see if it works.code:
(...)
xmlhttp.onreadystatechange = function () {
if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
// Data is available now
DoSomethingUseful(xmlhttp.responseText);
}
}
}
xmlhttp.send();
And forget about while loops for doing that. Seriously. Forget it.
I figured the problem
xmlhttp.send(data); doesn't appear to work
Well, it sends the data, but it doesn't retrieve what the file outputs.
Debug.Trace(xmlhttp.readyState); shows "1" so the connection's been opened but no data sent, but the data has been sent.
This is mighty confusing.