468,771 Members | 1,812 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,771 developers. It's quick & easy.

Datagrid: Old data after update

I did some searchs, but can't find the answer to my problems.

I have a editable DataGrid.
I do an update of one of the rows.
Postback "OnUpdateCommand"
Call Oracle proc to do that actual update, which in turn creates a new
row (effective dating).
Call BindGrid which retrieves the rows and binds the data to the grid
again.

Old data is showing in the DataGrid still. If I do a Edit then cancel
the new data shows. If I step through the code (ie: take some time)
the new data will show.

I'm running locally. I'm thinking it's something to do with IE caching
the data, but can't figure it out. ie 6.0.

Apr 19 '06 #1
2 1328
Check the procedure that loads data unto the grid when it loads before your
update make sure it only loads when your page is not posting back i.e

if (!Page.IsPostBack)
{
grid.DataSource = GetDataSource();
grid.DataBind();
}

there is a posibility that the grid re-binds with the old values before the
OnUpdateCommand executes.
"marty" <mp***@jump-technologies.com> wrote in message
news:11**********************@t31g2000cwb.googlegr oups.com...
I did some searchs, but can't find the answer to my problems.

I have a editable DataGrid.
I do an update of one of the rows.
Postback "OnUpdateCommand"
Call Oracle proc to do that actual update, which in turn creates a new
row (effective dating).
Call BindGrid which retrieves the rows and binds the data to the grid
again.

Old data is showing in the DataGrid still. If I do a Edit then cancel
the new data shows. If I step through the code (ie: take some time)
the new data will show.

I'm running locally. I'm thinking it's something to do with IE caching
the data, but can't figure it out. ie 6.0.

Apr 19 '06 #2
I verified that already. All of my pages have that if statement. This
only seems to be happening with IE. Firefox doesn't show the old
values.

Apr 20 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

9 posts views Thread by Pam Ammond | last post: by
4 posts views Thread by Glenn Owens | last post: by
3 posts views Thread by Jim Heavey | last post: by
reply views Thread by Steve | last post: by
3 posts views Thread by D. Shane Fowlkes | last post: by
4 posts views Thread by tshad | last post: by
5 posts views Thread by junglist | last post: by
1 post views Thread by Sharon | last post: by
9 posts views Thread by rn5a | last post: by
1 post views Thread by CARIGAR | last post: by
1 post views Thread by Marin | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.