473,396 Members | 1,766 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.

Page number caption?

LL
Hi,

I'm using DBGrid.

Can I add a caption "Page:" in front of the PageNumber:
Page: 1.2....

Thanks.
Nov 18 '05 #1
2 934
Yes you can. You have to find the Pager row and stick the
literal Page in their.

To do that wire the datagrid's ItemCreated event with the
following method.

private void dgTest_ItemCreated(object sender,
System.Web.UI.WebControls.DataGridItemEventArgs e)
{
try
{
if (e.Item.ItemType == ListItemType.Pager)
{
TableCell pc = new TableCell();
pc = (TableCell)e.Item.Controls[0];
string strPg = "<b>Page: </b>";
pc.Controls.AddAt(0, new
LiteralControl(strPg));
}
}
catch()
{

}
}

That should do it.
Suresh.
-----Original Message-----
Hi,

I'm using DBGrid.

Can I add a caption "Page:" in front of the PageNumber:
Page: 1.2....

Thanks.
.

Nov 18 '05 #2
LL
Thanks Suresh!
Nov 18 '05 #3

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

Similar topics

21
by: Gavin | last post by:
Hi, I'm a newbie to programming of any kind. I have posted this to other groups in a hope to get a response from anyone. Can any one tell me how to make my VB program read the Bios serial number...
2
by: and | last post by:
Hi I have been validating all day most things are cool but I cant get by this problem. One I have listed the script (JAVASCRIPT ) in all the right placesnot a prob but the validator insists...
3
by: CSDunn | last post by:
Hello, I have a situation with MS Access 2000 in which I need to display report data in spreadsheet orientation (much like a datasheet view for a form). If you think of the report in terms of what...
23
by: Davey | last post by:
How do I display an integer in binary format in C? e.g. 4 displayed as "100"
1
by: Chris Richards | last post by:
I am working with the Windows Media Encoder SDK, and at one point in the code, I have a need to display the Property Page of a Device plugin. The only code I have for doing this is written in C++...
0
by: Chris Ericoli | last post by:
Hi, I am working with an 'in session' ado dataset with an asp.net application. My dataset is comprised of two tables, one of which maintains a few calculated datacolumns. For some reason these...
6
by: Tony Doyle | last post by:
All, I have a web form with 3 embedded panels, all working fine. However, I have now added a Checkbox where autopostback=true, and only the ascx pages on my page appear, none of the panels /...
1
by: DavidB | last post by:
I want to be able to find the value of the Caption property of a Page in my Tab Control based solely on the Page Index property value. Is this possible? Example... tcBedrock pFred - Page...
7
by: imtmub | last post by:
I have a page, Head tag Contains many Scripts and style sheet for Menu and Page. This code working fine and displaying menus and page as i wanted. Check this page for reference....
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: 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
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:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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,...
0
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...
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
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,...

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.