Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 128641
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T05:40:04+00:00 2026-05-11T05:40:04+00:00

I have a gridview that could end up displaying about 5K records. I currently

  • 0

I have a gridview that could end up displaying about 5K records. I currently have it setup to use paging so it displays 200 records at a time. To add usability I’d like to provide the end user with some feedback that will allow them to locate a record easier. I was hoping there was a way that the user could put the mouse over one of the pager links and a tooltip would display the range of records available on the page.

For instance:

The user puts the mouse over the Page #1 link and the tooltip reads ABOTT – BUELLER The user puts the mouse over the Page #14 link and the tooltip reads MARTIN – PELLIGRINO

How would I accomplish this in ASP.NET?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T05:40:05+00:00Added an answer on May 11, 2026 at 5:40 am

    You could do the following. First create an empty PagerTemplate:

    <asp:GridView  ID='GridView1'  runat='server'  AllowPaging='true'  PagerSettings-Mode='Numeric'  PageSize='2' ondatabound='GridView1_DataBound'>     <PagerTemplate /> </asp:GridView> 

    Now in response to the DataBound event you can add controls to the pager row. This code just adds the page numbers as LinkButtons.

    protected void GridView1_DataBound(object sender, EventArgs e) {     GridViewRow pagerRow = GridView1.BottomPagerRow;      for (int i = 0; i < GridView1.PageCount; i++)     {         LinkButton lb = new LinkButton();         lb.Text = i.ToString();         lb.ToolTip = '...';         lb.CommandName = 'Page';         lb.CommandArgument = i.ToString();          pagerRow.Cells[0].Controls.Add(lb);     }  } 

    You’ll also need to handle the PageIndexChanging event.

    protected void GridView1_PageIndexChanging(object sender, GridViewPageEventArgs e) {     GridView1.PageIndex = e.NewPageIndex + 1;     GridView1.DataBind(); } 

    Now all that remains is to work out what the ToolTip text should be. For that you’ll need the indices of the top and bottom rows for every page. In this example they would be:

    int topIndex = i * GridView1.PageSize; int bottomIndex = ((i + 1) * GridView1.PageSize) - 1; 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a gridview that displays items details, I added two template fields one
I have a Gridview that displays a huge list of products. On Client click
I have a fairly standard ASP.NET GridView that displays 2 columns that have a
I have a gridview that displays the contents of a database table, using an
I have a GridView that uses LinqDataSource. The GridView has default paging enable. I
I have a GridView that I would like to bind to an ObjectDataSource. I
I have a GridView that allows editing the values in every column, in every
I have a gridview that is using a LinqDataSource for it's datasource. I've added
I have a gridview that is within an updatepanel for a modal popup I
I have a gridview that I have added a checkbox column using a templatefield

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.