John Martin wrote:
I have a web site that basically builds and displays reports. Some of the
reports take a long time to build (up to 10 minutes). I'd like to display a
"Please Wait" screen while the report is being built. Does anyone know how
to do this?
Thanks,
John
The basic premise most solutions use is to use a Session variable that
will hold a flag to tell you when the report-building process is done.
In your case, it could be the report itself, or just a boolean, that's
an arch. decision to be made based on how much traffic your site has, etc.
Then, what you do is spawn off a separate thread to do the processing,
meanwhile redirect your user to your 'wait page', setting a META tag to
tell it to auto-refresh every so many seconds:
<meta http-equiv="Refresh" content="10">
So every 10 sec it'll refresh itself, during which you check to see if
the Session variable is filled (meaning the report is ready). If so,
you redirect to your 'display report' page.
--
Craig Deelsnyder
Microsoft MVP - ASP.NET