473,659 Members | 2,722 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Transition Page

Anyone know what I can do to build a transition page while ASP code runs in
the background? Looking for something to say "Please wait while
loading....."
Jul 19 '05 #1
16 2610
Please wait while loading.

<% Response.Flush
'''code that takes a really long time
%>
Thanks for waiting.

Here's some more info. http://www.darkfalz.com/1058/

Ray at work

"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:uI******** ******@TK2MSFTN GP09.phx.gbl...
Anyone know what I can do to build a transition page while ASP code runs in the background? Looking for something to say "Please wait while
loading....."

Jul 19 '05 #2
Make sure to put Response.write Space(256) before the Response.flush.
IE has a behaviour (bug?) where it won't display any part of the page
until at least 256 bytes have been sent. Here are three functions you
can use.
' Wait page functions
Sub PrintWaitPageHe ader(strHeaderM essage)
Response.write "<html><body>"& vbCrLf
Response.write "<h2>"&strHeade rMessage&"</h2>"&Space(256) &vbCrLf
Response.Flush
End Sub

Sub PrintWaitPageSt atus(strStatusM essage)
Response.write strStatusMessag e&Space(256)&vb CrLf
Response.Flush
End Sub

Sub PrintWaitPageCo mplete(strRedir ectURL)
Response.write "<script type="&Chr(34)& "text/javascript"&Chr (34)&">"&vbCrLf
Response.write "document.locat ion.href='"&str RedirectURL&"'; "&vbCrLf
Response.write "</script>"&vbCrLf
Response.write "<p>"&Space(256 )&vbCrLf
Response.write "<p>If the page does not transfer, <a href="&_
Chr(34)&strRedi rectURL&Chr(34) &">click here.</a>"&vbCrLf
Response.write "</body></html>"
Response.Flush
End Sub

Shailesh

Roger Cantillo wrote:
Anyone know what I can do to build a transition page while ASP code runs in
the background? Looking for something to say "Please wait while
loading....."


Jul 19 '05 #3
Will Response.Flush give any trouble when accessing form data via
Request.Form?
"Shailesh Humbad" <hu******@hotma il.com> wrote in message
news:eu******** **************@ twister.columbu s.rr.com...
Make sure to put Response.write Space(256) before the Response.flush.
IE has a behaviour (bug?) where it won't display any part of the page
until at least 256 bytes have been sent. Here are three functions you
can use.
' Wait page functions
Sub PrintWaitPageHe ader(strHeaderM essage)
Response.write "<html><body>"& vbCrLf
Response.write "<h2>"&strHeade rMessage&"</h2>"&Space(256) &vbCrLf
Response.Flush
End Sub

Sub PrintWaitPageSt atus(strStatusM essage)
Response.write strStatusMessag e&Space(256)&vb CrLf
Response.Flush
End Sub

Sub PrintWaitPageCo mplete(strRedir ectURL)
Response.write "<script type="&Chr(34)& "text/javascript"&Chr (34)&">"&vbCrLf Response.write "document.locat ion.href='"&str RedirectURL&"'; "&vbCrLf
Response.write "</script>"&vbCrLf
Response.write "<p>"&Space(256 )&vbCrLf
Response.write "<p>If the page does not transfer, <a href="&_
Chr(34)&strRedi rectURL&Chr(34) &">click here.</a>"&vbCrLf
Response.write "</body></html>"
Response.Flush
End Sub

Shailesh

Roger Cantillo wrote:
Anyone know what I can do to build a transition page while ASP code runs in the background? Looking for something to say "Please wait while
loading....."

Jul 19 '05 #4
I tried response.flush and it works great. The reason I ask is because I'm
submitting a lot of data via the POST method, and I don't want to lose any
of it. Just being overly cautious.
"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:uI******** ******@TK2MSFTN GP10.phx.gbl...
What sort of trouble? Have you tried what you want to do to see? You can
response.flush as much as you want, but the request collection will still be there available to you until the point of response.end.

Ray at work

"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:e8******** ******@TK2MSFTN GP10.phx.gbl...
Will Response.Flush give any trouble when accessing form data via
Request.Form?


Jul 19 '05 #5
Ah, that's what's testing is for...

<form method="post" action="test.as p">
<input name="x">
<input type="submit">
</form>

<%
response.write request.form("x ") & "<hr>"
response.flush
response.write "Request was flushed. Can I still get x?<br>"
response.write request.form("x ")
response.end
%>

Ray at work
"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:Ol******** ******@tk2msftn gp13.phx.gbl...
I tried response.flush and it works great. The reason I ask is because I'm submitting a lot of data via the POST method, and I don't want to lose any
of it. Just being overly cautious.
"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:uI******** ******@TK2MSFTN GP10.phx.gbl...
What sort of trouble? Have you tried what you want to do to see? You can response.flush as much as you want, but the request collection will
still be
there available to you until the point of response.end.

Ray at work

"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:e8******** ******@TK2MSFTN GP10.phx.gbl...
Will Response.Flush give any trouble when accessing form data via
Request.Form?



Jul 19 '05 #6
"Shailesh Humbad" <hu******@hotma il.com> wrote in message
news:eu******** **************@ twister.columbu s.rr.com...
Make sure to put Response.write Space(256) before the Response.flush.
IE has a behaviour (bug?) where it won't display any part of the page
until at least 256 bytes have been sent. Here are three functions you
can use.


Great tip. No wonder I could never make this work before!

-Jon

Jul 19 '05 #7
I asked the same original question a few minutes ago and was referred to
this thread...and it is 90% of what I want. The only problem that I have is
that I want to get rid of the "Please wait message" after the page has
filled. Am I looking at some sort of redirect???

TIA,

Larry Woods

"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
Ah, that's what's testing is for...

<form method="post" action="test.as p">
<input name="x">
<input type="submit">
</form>

<%
response.write request.form("x ") & "<hr>"
response.flush
response.write "Request was flushed. Can I still get x?<br>"
response.write request.form("x ")
response.end
%>

Ray at work
"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:Ol******** ******@tk2msftn gp13.phx.gbl...
I tried response.flush and it works great. The reason I ask is because

I'm
submitting a lot of data via the POST method, and I don't want to lose any
of it. Just being overly cautious.
"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:uI******** ******@TK2MSFTN GP10.phx.gbl...
What sort of trouble? Have you tried what you want to do to see? You

can response.flush as much as you want, but the request collection will

still
be
there available to you until the point of response.end.

Ray at work

"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:e8******** ******@TK2MSFTN GP10.phx.gbl...
> Will Response.Flush give any trouble when accessing form data via
> Request.Form?



Jul 19 '05 #8
Flushing the Response object should have no effect on any part of the
Request object.

I had the transition pages working in Mozilla, but they failed in IE.
So a lot of Google hunting later, I found the tip. I'm glad you like it
too! :)

S.

Roger Cantillo wrote:
Will Response.Flush give any trouble when accessing form data via
Request.Form?
"Shailesh Humbad" <hu******@hotma il.com> wrote in message
news:eu******** **************@ twister.columbu s.rr.com...
Make sure to put Response.write Space(256) before the Response.flush.
IE has a behaviour (bug?) where it won't display any part of the page
until at least 256 bytes have been sent. Here are three functions you
can use.
' Wait page functions
Sub PrintWaitPageHe ader(strHeaderM essage)
Response.writ e "<html><body>"& vbCrLf
Response.writ e "<h2>"&strHeade rMessage&"</h2>"&Space(256) &vbCrLf
Response.Flus h
End Sub

Sub PrintWaitPageSt atus(strStatusM essage)
Response.writ e strStatusMessag e&Space(256)&vb CrLf
Response.Flus h
End Sub

Sub PrintWaitPageCo mplete(strRedir ectURL)
Response.writ e "<script


type="&Chr(34)& "text/javascript"&Chr (34)&">"&vbCrLf
Response.writ e "document.locat ion.href='"&str RedirectURL&"'; "&vbCrLf
Response.writ e "</script>"&vbCrLf
Response.writ e "<p>"&Space(256 )&vbCrLf
Response.writ e "<p>If the page does not transfer, <a href="&_
Chr(34)&strRe directURL&Chr(3 4)&">click here.</a>"&vbCrLf
Response.writ e "</body></html>"
Response.Flus h
End Sub

Shailesh

Roger Cantillo wrote:

Anyone know what I can do to build a transition page while ASP code runs
in
the background? Looking for something to say "Please wait while
loading..... "



Jul 19 '05 #9
Put the message in a div or span tag and give it a unique id, like:
<div id="waitmessage ">Please wait...</div>

In the Javascript, replace the line that does the redirect
(location.href= ...) with a call to the show/hide functions from here:

http://getelementbyid.com/scripts/index.aspx?CodeID=5

If you want the message to collapse out of the page as well as
disappear, then add a line like:

document.getEle mentById(id).st yle.position = "absolute";

to collapse, and if you want to show again, like:

document.getEle mentById(id).st yle.position = "relative";

This should work like a charm in most browsers nowadays. There are a
lot of other ways to hide the "please wait" message once the page loads,
but these are more appropriate for a Javascript/HTML forum.

Shailesh
Larry Woods wrote:
I asked the same original question a few minutes ago and was referred to
this thread...and it is 90% of what I want. The only problem that I have is
that I want to get rid of the "Please wait message" after the page has
filled. Am I looking at some sort of redirect???

TIA,

Larry Woods

"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
Ah, that's what's testing is for...

<form method="post" action="test.as p">
<input name="x">
<input type="submit">
</form>

<%
response.writ e request.form("x ") & "<hr>"
response.flus h
response.writ e "Request was flushed. Can I still get x?<br>"
response.writ e request.form("x ")
response.en d
%>

Ray at work
"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:Ol****** ********@tk2msf tngp13.phx.gbl. ..
I tried response.flush and it works great. The reason I ask is because


I'm
submitting a lot of data via the POST method, and I don't want to lose
any
of it. Just being overly cautious.
"Ray at <%=sLocation% >" <myfirstname at lane34 dot com> wrote in message
news:uI***** *********@TK2MS FTNGP10.phx.gbl ...

What sort of trouble? Have you tried what you want to do to see? You


can
response.fl ush as much as you want, but the request collection will


still
be

there available to you until the point of response.end.

Ray at work

"Roger Cantillo" <ro****@axiomsw .com> wrote in message
news:e8**** **********@TK2M SFTNGP10.phx.gb l...

>Will Response.Flush give any trouble when accessing form data via
>Request.Fo rm?



Jul 19 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
5067
by: Richard A. DeVenezia | last post by:
I hope this is the end of my present 'discovery' phase. I've learned alot about JavaScript in a short time and my head hurts. The following is what came out of all my questions and all the excellent answers (thanks!). It will be the basis of a slightly more complicated function for rendering a two-level navigation bar ( Don't have time to get into design of a multi-styletype renderer for n-level hierarchies. ) This is a single function...
8
3042
by: Workgroups | last post by:
I've got a page where the nature of the beast is such that the user clicks a submit button to ransomize some data in somewhat rapid succession (once per second, give or take). The page generates a little table, 10x10, of small pictures that represent the randomized data. The submit button tells the server (which is keeping track of which pictures are where) to scramble them around and output a new table. The output is simple HTML. The...
1
3140
by: Busy | last post by:
Hello Everyone Please can someone point me in the direction of a really good tutorial or discussion on PHP page transition? What I'm looking for is coverage of page transition that covers: Breaking out of frames in PHP - for and against arguments with examples; Carrying forward variables - the various methods of moving variables from
1
5812
by: Michel Esber | last post by:
Hello, DB2 V8 FP 10 running Linux RedHat 4.0. I have created a system temporary tablespace and now I want to delete it. However: $ db2 "drop tablespace reorg" DB21034E The command was processed as an SQL statement because it was not a valid Command Line Processor command. During SQL processing it
1
1166
by: dotnettester | last post by:
Hi, I have a secure page that users use to login to the site. Once the user has successfully signed in I transfer him to a nonsercure content page. But at this transition user is prompted that he is being transferred from secure site to a non-secure site. Is there a way I can avoid this prmopt msg? Thnx
2
2693
by: Emil | last post by:
Hi, if you open the link below and click on "Show Me" and then "Toggle Transition" Button you will see a wonderfull fade in / fade out transition of 2 pictures. http://msdn.microsoft.com/library/default.asp?url=/workshop/author/filter/reference/filters/fade.asp I want to have the same effect in Visual C++, dosen't matter with / or without GDI+, but no .NET. I have a simple dialog with some controls and I
14
5947
by: Gale | last post by:
I wrote a simple script for image rotation. now i need to have some transition effect betwean images in JS What do you suggest ? Thank you
2
1954
by: | last post by:
Is it possible to use IE transition effects (e.g. progid:DXImageTransform.Microsoft.Fade(Duration=2)">) to smooth "classic" (IE non-ATLAS) datagrid paging? How do you wire up the transition effect to fire with each paging event, (versus page load, which won't show on paging event.) I'm pretty sure this is possible: unless Jeff Prosise dummied up his entire demo, he had something like this miming ATLAS-ish effects at the Tech Ed...
4
2096
by: scoobydoo9749 | last post by:
So I was on here the other day looking for help with the getElementByName method and recieved excellent help quickly. (Thankyou GITS) Now, I'm looking for some help with making some dynamic content transition (every 4 seconds). Essentially what I have is 5 hidden divs in a php page. In my javascript code they get stored into an array and the setTimeout method is used to call then them one after the other. Instead of just having them switch I...
0
8851
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8746
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8525
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8627
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7356
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6179
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
1
2750
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1975
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1737
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.