473,386 Members | 1,712 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Again: Console-ish output in a browser?

Well, I initiated this discussion a few days ago at:

http://groups.google.com/group/micro...1325ee69224a8c

I tried the suggested approach and created a page like this:

Response.Buffer = false;
Response.Write("Something ... ");
System.Threading.Thread.Sleep(2000);
Response.Write("Something else ... ");
System.Threading.Thread.Sleep(2000);
Response.Write("Some other stuff ... ");
System.Threading.Thread.Sleep(2000);

It looks like that it works only if you enter the URL of this page in
the address bar of the browser and hit enter.

But, if this page is directed to from another page through either a
button click (Button or LinkButton does not matter) or even an anchor
href, it does not work! You will only see the end of the output.

Try it out and you'll see the problem.

Any fix of this problem?

Thanks.
Dec 28 '07 #1
2 1012
Hi,

Try to add a Response.Flush() before the Thread.Sleep call

Regards,

Paulo Santos
http://pjondevelopment.50webs.com

On Dec 28, 1:39*pm, gnewsgroup <gnewsgr...@gmail.comwrote:
Well, I initiated this discussion a few days ago at:

http://groups.google.com/group/micro...framework.aspn...

I tried the suggested approach and created a page like this:

Response.Buffer = false;
Response.Write("Something ... ");
System.Threading.Thread.Sleep(2000);
Response.Write("Something else ... ");
System.Threading.Thread.Sleep(2000);
Response.Write("Some other stuff ... ");
System.Threading.Thread.Sleep(2000);

It looks like that it works only if you enter the URL of this page in
the address bar of the browser and hit enter.

But, if this page is directed to from another page through either a
button click (Button or LinkButton does not matter) or even an anchor
href, it does not work! *You will only see the end of the output.

Try it out and you'll see the problem.

Any fix of this problem?

Thanks.
Dec 28 '07 #2
On Dec 28, 11:06 am, PJ on Development <pjondevelopm...@gmail.com>
wrote:
Hi,

Try to add a Response.Flush() before the Thread.Sleep call

Regards,

Paulo Santoshttp://pjondevelopment.50webs.com
Exactly that's the problem. Thank you very much for helping me
resolve it
Dec 28 '07 #3

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

Similar topics

19
by: Dave | last post by:
Hi, I have done some research, trying to Clear The Screen in java code. The first option was the obv: system.out.print("\n\n\n\n\n\n\n\n\n\n\n\n"); then i heard about this method:...
56
by: Dave Vandervies | last post by:
I just fixed a bug that some of the correctness pedants around here may find useful as ammunition. The problem was that some code would, very occasionally, die with a segmentation violation...
3
by: Sunny | last post by:
Hi again, in the past I have posted here a problem with static methods and abstract classes, and Jon Skeet and Richard Lowe have helped me to clarify the things. But now I have found another...
3
by: julien | last post by:
Hello, I'm sorry to send another message about the custom assemblies. The examples I find online don't help to find out what is wrong in my file. In a dll: This custom attribute: public...
6
by: Daniel Sélen Secches | last post by:
I've tried to download a file from a ftp server using it... but it doesn't work.... does anyone has already used it? Thank's..... Private Declare Function InternetCloseHandle Lib...
20
by: Woody Splawn | last post by:
In a message yesterday titled Try Catch Question I got numerous responses. Thank you to all. After all the smoke clears I guess the question is where to place the Return True statement in the...
33
by: Ruffin Bailey | last post by:
I coulda sworn I was given an explanation during an AppDev class years ago for VB6, but don't recall the answer. Why is it that -1 is True in Visual Basic (and now VB.NET)? Bit flags seem like...
3
by: ano | last post by:
How to reset Mutex.ReleaseMutex()? I can't call Mutex.WaitOne() again because the Mutex status seem to be fix to ReleaseMutex(). Do I need to create new Mutex() every time after ReleaseMutex()? ...
10
by: Jeff | last post by:
I guess that I should have explained better (I'm stil new with this, so I may not be asking the questions in the best way) Normally, one would use the simple code: if x>y then something end...
10
by: Scott Townsend | last post by:
So I need to talk to a devices that expects all of the bits and bytes I sent it to be in specific places (not yet 100% defined). I wanted to create a structure/class with all of the data in it...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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,...

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.