Solved

page refresh or display waiting in asp

Posted on 2001-07-08
6
225 Views
Last Modified: 2010-05-18
Hi,  Im using an asp page that runs a bunch of things on the server.  It is initiated by the user clicking a button on the page.  Because this takes a while, I want to display a simple message on the page to say that is is currently working.  Now, whatever I write doesn't appear on the screen until the process is complete.  Any Ideas?
0
Comment
Question by:b9frosty
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 5

Expert Comment

by:mattyk
ID: 6262398
The most foolproof way to handle this is to have your hyperlink go to an intermediate html page which would look something like this

<script>
window.location="yourASPpage.asp"
</script>
<body>
Please Wait Loading Page...
</body>


of course the page can say look like anything you'd like.

-matty
0
 

Author Comment

by:b9frosty
ID: 6262423
Is it possible to keep the same page visible that I have and just add a line that says "Please Wait"?  I'm not sure I can do it since the page has already been sent to the browser unless I can append it throught the asp.  If not, I'll do it the way you described.  Thanks.
0
 
LVL 9

Expert Comment

by:TTom
ID: 6262554
If you don't mind using the status bar, you can do something like this:

At the top of your ASP code (right under the language designation), add:

<%response.buffer=true%>
<script>
<%response.write "status='Loading this Page'"%>
</script>
<%Response.Flush%>

Then, in the <BODY> tag, add, "onload='status="Done;"'" (without the outside "s).

You can also use this script to open a popup window which closes when the page is finished loading.

You could probably do something similar using a <div> which you could flush down to the browser and then remove from the display when the page was loaded.  Michel Plungjan (mplungjan) has posted JavaScript code for such an item.  If this seems promising I can look around for the code.  It functions like a popup window.

Tom
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 6

Expert Comment

by:andyclap
ID: 6263028
You could turn buffering off for your page, and avoid putting results in tables (most browsers have to receive the whole table before it can work out how to render it).
0
 
LVL 33

Expert Comment

by:hongjun
ID: 8622521
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
[PAQ with NO REFUND]

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

hongjun
EE Cleanup Volunteer
0
 

Accepted Solution

by:
SpideyMod earned 0 total points
ID: 8674279
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Recordset containing single quotes 8 48
document.getElementById not worj with 2 IDs with the same name 10 57
send email part1 9 39
Clear input text 15 26
I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:   The Exchange of informatio…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
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…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

735 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