[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

ASP.NET DataGrid Image does not Refresh after Edit Mode

Posted on 2004-09-13
3
Medium Priority
?
237 Views
Last Modified: 2012-06-21
Thanks to other EE users I was able to add image uploading to my datagrid. However now when it goes back after the edit (new image uploaded) it shows the original image and not the new one unless I hit f5 and refresh the browser.

How can I fix this?

I'm using the following in the PageLoad sub and it calls the database and loads the new info into the datagrid.

If Not IsPostBack Then
    BindDataGrid()
End If
0
Comment
Question by:brian2k1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 7

Expert Comment

by:mantarae
ID: 12043287
After the edit takes place (ie, in your edit_command function), you need to call BindDataGrid() again.   Do not put it in the Page_Load function, otherwise the grid would be rebound before your edit is saved.
0
 
LVL 1

Author Comment

by:brian2k1
ID: 12072014
No. It updates fine. It's the IMAGES being displayed that do not refresh. I guess my question is how can I force the browser to update the images or disable their cache for the page.
0
 
LVL 7

Accepted Solution

by:
mantarae earned 2000 total points
ID: 12135563
Oops...misread your question (and was out of town).   Try this:

Launch the Internet Services Manager, navigate to the images directory in question, then right-click the folder, and choose Properties. In the Properties dialog box, select HTTP Headers, and then click Add. Enter the following three headers:

cache-control:no-cache
pragma:no-cache
expires:0

from:
http://www.developerfusion.com/show/228/
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question