473,396 Members | 2,011 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,396 software developers and data experts.

How to show the refresh time of a web page

ad
I have a web page which show a lot of data, it waste a lot of time to show
the data.
I wnat to know how much time it take to show the data.
How can I get it?
Oct 29 '06 #1
3 1610
You can use the StopWatch class or just set a DateTime field with
DateTime.Now at the very beginning of page processing (you pick the event you
want to start with) and then say, in Page_Unload, you would set a new
DateTime field to DateTime.Now. Take the timespan difference by subtracting
the first from the last, and get the TotalMilliseconds.
Of course, reading between the lines, this is only going to tell you
something you already know: your page is taking a long time to display data.
Better to investigate why this may be happening and work to create a more
efficient way to get what you want.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"ad" wrote:
I have a web page which show a lot of data, it waste a lot of time to show
the data.
I wnat to know how much time it take to show the data.
How can I get it?
Oct 29 '06 #2
ad
Thanks,
What is the event at the very begining of a page creating?
"Peter Bromberg [C# MVP]" <pb*******@yahoo.nospammin.com¼¶¼g©ó¶l¥ó·s»D:3B*** *******************************@microsoft.com...
You can use the StopWatch class or just set a DateTime field with
DateTime.Now at the very beginning of page processing (you pick the event
you
want to start with) and then say, in Page_Unload, you would set a new
DateTime field to DateTime.Now. Take the timespan difference by
subtracting
the first from the last, and get the TotalMilliseconds.
Of course, reading between the lines, this is only going to tell you
something you already know: your page is taking a long time to display
data.
Better to investigate why this may be happening and work to create a more
efficient way to get what you want.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"ad" wrote:
>I have a web page which show a lot of data, it waste a lot of time to
show
the data.
I wnat to know how much time it take to show the data.
How can I get it?

Oct 29 '06 #3
Ad,

Enable trace. It will help you to identify which place takes long time to
execute. Go to web.config file, put this
<trace enabled="true" pageOutput="true" requestLimit="1000"/>
under <system.websection. (You can also use it from trace.axd utility page
when pageOutput is set to false)

Milosz Skalecki
MCAD
"ad" wrote:
Thanks,
What is the event at the very begining of a page creating?
"Peter Bromberg [C# MVP]" <pb*******@yahoo.nospammin.com¼¶¼g©ó¶l¥ó· s»D:3B**********************************@microsof t.com...
You can use the StopWatch class or just set a DateTime field with
DateTime.Now at the very beginning of page processing (you pick the event
you
want to start with) and then say, in Page_Unload, you would set a new
DateTime field to DateTime.Now. Take the timespan difference by
subtracting
the first from the last, and get the TotalMilliseconds.
Of course, reading between the lines, this is only going to tell you
something you already know: your page is taking a long time to display
data.
Better to investigate why this may be happening and work to create a more
efficient way to get what you want.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"ad" wrote:
I have a web page which show a lot of data, it waste a lot of time to
show
the data.
I wnat to know how much time it take to show the data.
How can I get it?


Oct 29 '06 #4

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

Similar topics

7
by: Rudy | last post by:
Hello All! After working in the television industry, moving to a developing career has been interesting to say the least. 3 years of developing with books, and the help of you fine folks on this...
8
by: Jason S | last post by:
Hi, is there any way of getting my VB (6.0) program to automatically 'Refresh' an IE window that might be active (window status not applicable). It needs to be able to determine which active IE...
5
by: =?Utf-8?B?Sm9obg==?= | last post by:
Hi, I used the following code to refresh the parent page, and it works very well (Thanks to Peter Bromberg "). Response.Write("<script language='javascript' type='text/javascript'{...
1
by: BibhuAshish | last post by:
Hi, I am using struts 2. I need to have a clock ticking every second in my webpage to show server time. I do not want to refresh my whole page every second and i do not want to use applet. Now...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
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...
0
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,...
0
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...

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.