473,385 Members | 1,523 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,385 software developers and data experts.

datagrid paging automatically (after 10 seconds)

Hello guys,

I have a Datagrid and .AllowPaging=true.... it is working well but I'd
like to page automatically after some seconds.
So the whole solution is a screen in our company showing some dates
which does not fit on 1 single screen so I'd like to automate the
Page-Event.

for example:
screen 1
after 10 seconds
screen 2 (second Page like if I click on page 2)
after 10 seconds
scrren 3 (like if I click on page 3)
..
..
..

It should work with forcing JavaScript to fire the next page-event
after 10 seconds, but do not know exactly.

Thanks a lot.
radioon.

Aug 26 '06 #1
1 1831
I was able to acheive the desired effect using JavaScript

Update your body tag with the following:
<body onload="setTimeout('PageDataGrid()', 10000)">

Add the following script:
<script type="text/javascript">
<!--
function PageDataGrid()
{
try
{
// Find 'Next-Page' link
var grid = document.getElementById("dataGrid");
var cell = grid.firstChild.lastChild.firstChild.lastChild;

// Simulate click
cell.click();
}
catch(err)
{
alert("Error occurred: " + err.Message);
}
}

//-->
</script>

--
James Johansen, Longhorn SDK
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
--------------------
>From: ge*****@gmx.at
Newsgroups: microsoft.public.dotnet.languages.csharp
Subject: datagrid paging automatically (after 10 seconds)
Date: 26 Aug 2006 05:15:33 -0700
Organization: http://groups.google.com
Lines: 24
Message-ID: <11**********************@h48g2000cwc.googlegroups .com>
NNTP-Posting-Host: 217.116.178.218
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
X-Trace: posting.google.com 1156594537 26277 127.0.0.1 (26 Aug 2006
12:15:37 GMT)
>X-Complaints-To: gr**********@google.com
NNTP-Posting-Date: Sat, 26 Aug 2006 12:15:37 +0000 (UTC)
User-Agent: G2/0.2
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1;
..NET CLR 1.1.4322; .NET CLR 1.0.3705; .NET CLR
2.0.50727),gzip(gfe),gzip(gfe)
>Complaints-To: gr**********@google.com
Injection-Info: h48g2000cwc.googlegroups.com; posting-host=217.116.178.218;
posting-account=tnarpw0AAAAgQvwM-hRJegr6J779QuN3
Path:
TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP01.phx.gbl!TK2MSFT FEEDS01.phx.gbl!newsfeed.c
w.net!cw.net!news-FFM2.ecrc.de!newsfeed.gamma.ru!Gamma.RU!postnews.g oogle.co
m!h48g2000cwc.googlegroups.com!not-for-mail
>Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.dotnet.languages.csharp:425571
X-Tomcat-NG: microsoft.public.dotnet.languages.csharp

Hello guys,

I have a Datagrid and .AllowPaging=true.... it is working well but I'd
like to page automatically after some seconds.
So the whole solution is a screen in our company showing some dates
which does not fit on 1 single screen so I'd like to automate the
Page-Event.

for example:
screen 1
after 10 seconds
screen 2 (second Page like if I click on page 2)
after 10 seconds
scrren 3 (like if I click on page 3)
.
.
.

It should work with forcing JavaScript to fire the next page-event
after 10 seconds, but do not know exactly.

Thanks a lot.
radioon.

Aug 30 '06 #2

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

Similar topics

2
by: enak | last post by:
I can not get my datagrid to page. I have a datagrid that I can sort 2 of the columns. This works great. I added paging and when I display the dg it shows 5 pages. (I am showing page numbers at...
2
by: Rathtap | last post by:
I am displaying data in a bound datagrid. Is there a way to provide paging through client-side script? That is, without re-loading the page. I am willing to have the initial overhead of bringing in...
5
by: Patrick.O.Ige | last post by:
Hi Guys, I have a datagrid wit editing and updating. But after adding Paging IT WON'T PAGE!! It compiles well but when i click on the paging link it doesn't go to the next link.. When i remove...
6
by: Shawn | last post by:
Hi. I already have a datagrid where I'm using paging. I have a stored procedure that fills a temp table with 200-500 rows and then sends back 10 records at the time. When I go to page 2 the SP...
5
by: quanga | last post by:
Hi- I have a datagrid that in some cases can be several thousand rows in length. What I'd like it to do is have the data pushed to the browser after every, say, 100 rows or so. Kind of a...
5
by: tshad | last post by:
Is there a way to carry data that I have already read from the datagrid from page to page? I am looking at my Datagrid that I page through and when the user says get the next page, I have to go...
0
by: Pat | last post by:
I have 3 Datagrid nested. Master Details Child The master has paging (And i'm using the paging inbuilt in the Datagrid) in the Master DataGrid you select a linkbutton(using commandname) and it...
3
by: Pat | last post by:
I have a 2 nested Datagrid. When i select a row in the Master Datagrid i populate the Child databrid using myDataGrid.SelectedIndex value as the filter and setting the DataKeyField. I enabled...
3
by: GD | last post by:
Got a simple ASPX page (.NET v1.1) with a DataGrid displaying a list of widgets. If the page has a QueryString called WidgetId specific, I need to automatically mark the specific DataGridItem as...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
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: 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...
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...

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.