I Learnt Today…

This is where I share things I learn day by day !

C# ASP.NET – GridView : How to Use Checkbox in Gridview to Select Multiple Rows

I moved my site to its own domain. Please use following link for the information you are looking for:

http://www.ilearnttoday.com/index.php/c-aspnet-gridview-select-multiple-rows-in-a-grid-view-using-check-boxes

January 6, 2009 - Posted by Menol | ASP.NET, C#.NET, GridView, Menol, Select Multiple Rows, Web Development | , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , | 11 Comments

11 Comments »

  1. Hi menol..I m a beginner for asp .net programming..your article really helped me and saved a lot of time for me..Good work..!

    Comment by Florence | February 1, 2009 | Reply

  2. how to fatch record from database which record i selected from datagridview using checkbox and that record i want to redirect on next page.

    Comment by madhuri | February 3, 2009 | Reply

  3. To Maduri,

    You want to fetch more details from the database depending on the selected record from the gridview and you want to forward that details to the next screen. If this is the scenario you want to get done…

    First you can get the details you want from selected rows in the gridview by

    1 Iterating through the gridview
    2 Identify the checked rows
    3 Extract data you want by referring to cells in selected rows

    Then you have to query the database to fetch records you want by including the details you extracted from the gridview into the SQL query.

    Then if you want to take those details into a next page, I recommend you to store those data in the session so you can use it from any page you want.

    I hope this helped you.

    If what you want is different from this, Please write your scenario so I can try to help you better.

    Regards,
    Menol

    Comment by Menol | February 4, 2009 | Reply

  4. Hi It is really a very very good example.
    I got to know many things.
    Do tell me how to add text in front of those checkboxes.

    Comment by Bhushan | February 26, 2009 | Reply

  5. how to store multiple rows in database from one click form gridview….with the help of girdview one multiple seclectin..k thnax in advance..

    Comment by saurabh bhatia | March 17, 2009 | Reply

  6. hai, thnks a lotttttttttt 4 ths article. u made my day!!!
    i was workng on ths kind of issue for past 2 days. Finally i gt it wth the help of ur article
    thanks once again

    Comment by Remya | March 20, 2009 | Reply

  7. Hi, its really a good article.
    This helped me alot in understanding Grid working.

    Thanks

    Comment by Waqas Ashraf | March 27, 2009 | Reply

  8. Hi,
    Its realy helpful to every one.

    Comment by Chaitanya | March 28, 2009 | Reply

  9. hey its really nice but i wanted to select just one row of grid and forward the values to the next page
    pls help me
    thank u

    Comment by shilpa amonkar | April 3, 2009 | Reply

  10. very good student are confused

    Comment by efsdvsdvsd | May 4, 2009 | Reply

  11. Thanks

    Comment by Nel_Pogi | May 28, 2009 | Reply


Leave a comment