Keep current page displayed untill new page is loaded

I just want to keep current page displayed untill new page is loaded in asp.net 2.0.
I don't want to see a blank page.

Ajax is not the solution for my problem.

Thanks a lot !
ICOTechAsked:
Who is Participating?
 
ChetOS82Connect With a Mentor Commented:
Most people use Javascript:

<script type="text/script">
function preCache() {
image1 = new Image();
image1.src = "image1.gif";

image2 = new Image();
image2.src = "image2.gif";
}
</script>
<body onload="preCache();">
0
 
prairiedogCommented:
Is it because the second page takes a long time to load?
0
 
ChetOS82Commented:
We are not sure what your issue is... Are you clicking a link to another page, and you don't want the current one to go away first?
0
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

 
ICOTechAuthor Commented:
Yes ChetOs82 is rigth I don't want to go away first and the second page is a page of my web application.

Do you have a solution ?

Sorry for my english I speak habitualy french.
0
 
ChetOS82Commented:
What you want is not possible.  When you click a link, the page is unloaded from memory.  The new page is then requested, processed, downloaded, and rendered.  Since they are two distinct events, you cannot keep on page up while the next one works.

There are ways of tackling this problem, but they depend on why the second page takes so long to load.

If it is doing some sort of processing, you could put up an intermediate page (which says something like "Searching..." or "Processing...").  If the page is just huge (several megs), then there isn't much you can do (other than make it smaller).  If it is loading a bunch of graphics, you could pre-cache the graphics in the first page.
0
 
ICOTechAuthor Commented:
Ok and how I can pre-cache the graphic ?
0
 
ICOTechAuthor Commented:
Somebody have another solution ? The last one not give a great result.
0
 
prairiedogCommented:
>>>Somebody have another solution ? The last one not give a great result.
I might have one if you answer my question.
0
 
ICOTechAuthor Commented:
Yes prairiedog, the second page takes 4 to 6 seconds to load.
0
 
prairiedogCommented:
OK.
As ChetOS82 mentioned before, it is not possible to keep the first page displayed while the request has been redirected to the second page. I believe what you need is to give user some feedback before the second page is fully loaded, instead of just a black page. If we can put something like a popup saying "The page is loading, please wait...", and the popup will disappear once the second is loaded. Is this option acceptable?
0
 
ICOTechAuthor Commented:
Is not acceptable for my client.
I just want to keep current page displayed untill new page is loaded or else load template master of the second page immediatly and the content after but I don't want to use ajax. I need postback to conserv my hystoric.

P.S : Sorry for my english I speak habitualy french
0
 
prairiedogCommented:
I didn't say AJAX in my previous post, did I? With pure JavaScript, we still can do what I mentioned in my previous post, but if it is not acceptable, then I am sorry you are pretty much in the dead end.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.