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 6826609
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T22:10:04+00:00 2026-05-26T22:10:04+00:00

I have a gridview that is databound to a list of custom objects. On

  • 0

I have a gridview that is databound to a list of custom objects. On the client side, the user can enter a price value in a textbox and click on a checkbox for every row in the gridview. The gridview supports pagination and contains dozens of pages. When data is changed in the gridview I don’t necessarily want to change entries in the database because the user could end up cancelling out of the page, but I do want to remember (for now) what was check on other pages.

I’m trying to figure out how to read all the values across all the pages in the gridview when the user clicks submit. I could setup event handlers for the textboxes and checkboxes but I still need to store the modifed list of custom objects. In ASP, is this normally done in the application cache or should I be storing stuff in the viewstate?

  • 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. Editorial Team
    Editorial Team
    2026-05-26T22:10:05+00:00Added an answer on May 26, 2026 at 10:10 pm

    You can store the values in ViewState or Session.
    When it’s time to update, you update the DB.

    It’s not normally done in the application cache since data should only persist for the user’s session.

    i.e.
    Load up your list of Products & Bind it to the gridview. Also store the Products to your Viewstate. When it’s time to add,update or delete a product, you make the changes to the Products object in ViewState.

    On your SaveClick Event you read the products from ViewState and update the DB.

    Just be sure to check for concurrency issues.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a form that contains a GridView control which is databound to an
I have a databound list view and can set all the column widths manually
I have a gridview that is databound in the code-behind using a stored procedure.
I have a list view that has a column databound to a list.Count see
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
I have an gridview that I am adding onclick events to a checkbox column

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.