Dear All

i want to load some data to grid view (which is not existing in the database currently)
and do some chages (putting tax rates etc) and caluculate totals and after all changes done
to update them on the database,

where can i keep those data temporaly ? and do the manupulation and then update datatbase finally
it seems i can't use row updating event on grid view(because i don't want to subit it to database untill
i update each and every row manualy)

what do you suggest ?

Always use a dataset to store data temporarily, which is fetched from any source. Datasets can hold data from database table in the same format.

Thanks for replies

i am using caching for this i have a problem with the following code

I can't retrive new values entered to datat grid only line no 2 gets the values others are not working, can any body give an idea why ?

if (Cache["DATASET"] != null)
            {

                DataSet ds = (DataSet)Cache["DATASET"];                
               1. ds.Tables["Comminv"].Rows[e.RowIndex]["price"] =Convert.ToDouble(e.NewValues["price"].ToString());

              2.  ds.Tables["Comminv"].Rows[e.RowIndex]["DiscountPer"] = 10;               
               3. string vatp = ((TextBox)DgridComminv.Rows[e.RowIndex].Cells[8].Controls[0]).Text.ToString();



                DgridComminv.DataBind();
                Cache.Insert("DATASET", ds, null, DateTime.Now.AddHours(24), System.Web.Caching.Cache.NoSlidingExpiration);

                DgridComminv.EditIndex = -1;
                GetGrndetailsfromCache();                

            }

thanks
regards
sumith

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.