0

I have a form on my web page, it allows to submit many queries to my website, every query is on a separate line in TextArea. Because waiting for all queries to complete is too long I would like to update the web page after every query completes - send result of one query to a web browser, new result should be appended to old results that are already on the web page.

How to do this in ASP.NET MVC 2?

I will be grateful for helpful responses.

Update

Thank you for all your answers but I decided to use JavaScript in web browser to poll server for data, here is my question about it Can't disable jQuery cache

Community
  • 1
  • 1
robert_d
  • 259
  • 1
  • 4
  • 18

3 Answers3

2

Read about Comet

Some projects from codeplex:

CD..
  • 72,281
  • 25
  • 154
  • 163
0

I would just flush using Response.Flush() each time when you complete part of the request.

svick
  • 236,525
  • 50
  • 385
  • 514
0

Checkout HTTP Server Push or Long Polling.

or this SO question on HTTP Streaming...

Cross-browser implementation of "HTTP Streaming" (push) AJAX pattern

Examples of Long Polling with generic code.

How do I implement basic "Long Polling"?

https://stackoverflow.com/questions/tagged/long-polling

Community
  • 1
  • 1
kervin
  • 11,672
  • 5
  • 42
  • 59