Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. GridView paging without DataSource control

GridView paging without DataSource control

Scheduled Pinned Locked Moved ASP.NET
databasephpcsscomquestion
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Mark J Miller
    wrote on last edited by
    #1

    I'm trying to implement paging on a data grid control, but because I'm not using a datasource control there is no way to tell the GridView what the total record count is (I'm only returning the requested records from the database instead of the entire, unpaged dataset). I've looked everywhere and I can't seem to find any examples which aren't returning the whole dataset and then filtering it locally.

    Code responsibly: OWASP.org Mark's blog: developMENTALmadness.blogspot.com Click here for Free Industry White Papers/Magazines! Bill Cosby - "A word to the wise ain't necessary - it's the stupid ones that need the advice."

    C 1 Reply Last reply
    0
    • M Mark J Miller

      I'm trying to implement paging on a data grid control, but because I'm not using a datasource control there is no way to tell the GridView what the total record count is (I'm only returning the requested records from the database instead of the entire, unpaged dataset). I've looked everywhere and I can't seem to find any examples which aren't returning the whole dataset and then filtering it locally.

      Code responsibly: OWASP.org Mark's blog: developMENTALmadness.blogspot.com Click here for Free Industry White Papers/Magazines! Bill Cosby - "A word to the wise ain't necessary - it's the stupid ones that need the advice."

      C Offline
      C Offline
      Christian Flutcher
      wrote on last edited by
      #2

      Are you looking for a Custom Paging?[^]

      M 1 Reply Last reply
      0
      • C Christian Flutcher

        Are you looking for a Custom Paging?[^]

        M Offline
        M Offline
        Mark J Miller
        wrote on last edited by
        #3

        I had hoped I was just missing something. But thank you for confirming that for me. Would it have been so hard to allow for this kind of scenario? Honestly, I am really shocked at times when I run into scenarios when it requires so much more work (ok, so I'm being a bit lazy) to follow a best practice.

        Code responsibly: OWASP.org Mark's blog: developMENTALmadness.blogspot.com Click here for Free Industry White Papers/Magazines! Bill Cosby - "A word to the wise ain't necessary - it's the stupid ones that need the advice."

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups