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. How to iterate through a dataset and show each record on the web page

How to iterate through a dataset and show each record on the web page

Scheduled Pinned Locked Moved ASP.NET
tutorialquestion
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
    MissionSuccess
    wrote on last edited by
    #1

    Hello All How can I perform goint to Next,Previous,First and last record of a dataset. All of these events will be fired on click of the respective button. I know that i have to use SqlDataReader but unable to implement the same. Any Code will be helpful for me. Ajay Kumar

    C 1 Reply Last reply
    0
    • M MissionSuccess

      Hello All How can I perform goint to Next,Previous,First and last record of a dataset. All of these events will be fired on click of the respective button. I know that i have to use SqlDataReader but unable to implement the same. Any Code will be helpful for me. Ajay Kumar

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

      MissionSuccess wrote:

      I know that i have to use SqlDataReader

      Not true. There are numerous ways to define a data source. You can set up the GridView, at least, to do this for you, but I prefer to write controls for the links and write a stored proc that takes a page number and count, and handle it myself.

      Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

      M 1 Reply Last reply
      0
      • C Christian Graus

        MissionSuccess wrote:

        I know that i have to use SqlDataReader

        Not true. There are numerous ways to define a data source. You can set up the GridView, at least, to do this for you, but I prefer to write controls for the links and write a stored proc that takes a page number and count, and handle it myself.

        Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

        M Offline
        M Offline
        MissionSuccess
        wrote on last edited by
        #3

        Agreed SqldataReader is forward only.... But how can i achieve this...without any grid I have a no of data for a record so i am not using datagrid. I am showing it in different textboxes and dropdowns. On the click of next or previous button the respected textboxes and dropdowns shd be filled automatically with the correct data. Ajay Kumar

        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