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. General Programming
  3. C#
  4. How to search data on DataGridView?

How to search data on DataGridView?

Scheduled Pinned Locked Moved C#
helptutorialquestion
2 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.
  • N Offline
    N Offline
    nhatvhm
    wrote on last edited by
    #1

    Hi, everyone Now, I'm use to data paging in DataGridView. When I search data on DataGridView that is just show data in present page. I would like get all data rows of DataTable that is being data paging on DataGridView. For example: pagesize = 5, DataTable have two pages. data in 1st page:

    name age
    John 21
    N.John 20
    Nancy 20
    Tomath 21
    Jan 22

    and data in 2nd page:

    name age
    Jany 20
    Alpha 21
    Don 22
    Bony 20
    Tomy 22

    One-page is present page. I'm beginning search data at "name" column as 'Tom'. It is just show one row in DataGridView. This data is correct when it show two rows in DataGridView. That is all. Did the way solve this problem? Can anyone help me?:confused:

    D 1 Reply Last reply
    0
    • N nhatvhm

      Hi, everyone Now, I'm use to data paging in DataGridView. When I search data on DataGridView that is just show data in present page. I would like get all data rows of DataTable that is being data paging on DataGridView. For example: pagesize = 5, DataTable have two pages. data in 1st page:

      name age
      John 21
      N.John 20
      Nancy 20
      Tomath 21
      Jan 22

      and data in 2nd page:

      name age
      Jany 20
      Alpha 21
      Don 22
      Bony 20
      Tomy 22

      One-page is present page. I'm beginning search data at "name" column as 'Tom'. It is just show one row in DataGridView. This data is correct when it show two rows in DataGridView. That is all. Did the way solve this problem? Can anyone help me?:confused:

      D Offline
      D Offline
      Dave Sexton
      wrote on last edited by
      #2

      What? Can you explain the problem a little better?

      But fortunately we have the nanny-state politicians who can step in to protect us poor stupid consumers, most of whom would not know a JVM from a frozen chicken. Bruce Pierson
      Because programming is an art, not a science. Marc Clifton
      I gave up when I couldn't spell "egg". Justine Allen

      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