synchronous callbacks don't work

G

Guest

I've discovered that when you register a callback with useAsync = false, it
still executes asynchronously. This can be fixed by modifiying the
WebForm_DoCallback method with the following code: (from line 36 of the
method to the first return statement)

if (useAsync) {
xmlRequest.onreadystatechange = WebForm_CallbackComplete;
}
callback.xmlRequest = xmlRequest;
xmlRequest.open("POST", theForm.action, useAsync);
xmlRequest.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded");
xmlRequest.send(postData);
if (!useAsync) {
WebForm_CallbackComplete();
}
return;

By using this code it is possible to use the callback for validation
purposes. Could this please be fixed in a new release of the .net 2.0
framework?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,416
Messages
2,571,560
Members
48,797
Latest member
shadowoftheunknown

Latest Threads

Top