Solved

ASP.Net redirecting via a "Please Wait" page

Posted on 2014-10-13
4
374 Views
Last Modified: 2014-10-16
Hi,

I have a page which potentially contains a very slow SQL query which can take a minute or two to run.

Rather than redirecting directly to this page, I first redirect to a page called SearchWait.aspx which displays a simple "please wait" message. On this page is the following event:

  Protected Sub Page_SaveStateComplete(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.SaveStateComplete

    Response.Redirect("SearchRun.aspx?queryid=" & Request.QueryString("queryid"))

  End Sub

Where SearchRun.aspx is the potentially slow page.

When I use this the browser gets to SearchRun.aspx, which is presumably via SearchWait.aspx, but I never see the content of SearchWait.aspx

How can I fix this?

Thanks,

Richard
0
Comment
Question by:rpm
  • 2
4 Comments
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 40378164
No sarcasm intended:  Do you understand the statelessness of the web?
0
 
LVL 1

Author Comment

by:rpm
ID: 40378645
Not sure what you mean there!

Richard
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 500 total points
ID: 40382243
Your intermediate page never returns to the client and as far as the client is concerned, this intermediate page does not exist. You need to either redirect from Javascript on client side, or use partial rendering to render please wait message on the slow page before it completely renders itself.

http://encosia.com/boost-aspnet-performance-with-deferred-content-loading/
0
 
LVL 1

Author Closing Comment

by:rpm
ID: 40383828
Thanks, very helpful!
0

Featured Post

MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question