473,396 Members | 2,139 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

WebControl/Cache-control question...

Hi,

I am new to WebControls, I have created a WebControl that is used to present
an image, the image bing presented is created on runtime, each client side
button click causes the image to change, this require to prevent this image
from being cached, I have tried to play around with:
Context.Response.AddHeader("Cache-Control", ... )
and with
Context.Response.Cache.SetCacheability(System.Web. HttpCacheability.NoCache)
BUT Still, the image is being extracted from the cache and the changes
cannot be seen...

What am I doing wrong here?
How can I prevent the image from being cached?

Any help, samples or pointers will be appreciated.

--
Nadav
http://www.sophin.com
Nov 19 '05 #1
1 1413
Do you create the image phisically? or do you just write the result of the
changes?

If you are writing the image to the disk you only need to delete any file
wich name contains a patern and create the new one with a different name.
That's the only option I can see as the caching issue it doesn't just depend
on the server but in the client browser.

Joaquin

"Nadav" <Na***@discussions.microsoft.com> wrote in message
news:1B**********************************@microsof t.com...
Hi,

I am new to WebControls, I have created a WebControl that is used to
present
an image, the image bing presented is created on runtime, each client side
button click causes the image to change, this require to prevent this
image
from being cached, I have tried to play around with:
Context.Response.AddHeader("Cache-Control", ... )
and with
Context.Response.Cache.SetCacheability(System.Web. HttpCacheability.NoCache)
BUT Still, the image is being extracted from the cache and the changes
cannot be seen...

What am I doing wrong here?
How can I prevent the image from being cached?

Any help, samples or pointers will be appreciated.

--
Nadav
http://www.sophin.com

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Owatona | last post by:
Hi to all... I have 3 classes derived from webcontrol. I the first i have two dropdownlist, in the second i have some buttons, and the third its the webcontrol that are instanciate the two...
0
by: chris | last post by:
Hi there, I have a webcontrol which should function like a button. Could I add an click action to the webcontrol (like you have ot on a button) or can I add an event handler to the webcontrol? ...
3
by: Mike Owen | last post by:
I have just tried to open a the file "Controls/CreateEditPost.cs" from within Visual Studio .Net, and the error message: 'An error occurred while loading the document. Fix the error, and then...
2
by: Novice | last post by:
I can't seem to get my Custom WebControl to output a button whose click event is associated with a particular method. Here is the code I have right now that contains a panel and there is a...
3
by: spmm# | last post by:
Hi! Could someone please help me with the following; I have a WebControl that basically looks like this: public class LeftMenu : System.Web.UI.WebControls.WebControl { private string...
4
by: Cesar Ronchese | last post by:
Hello. I have a WebForm that contains a Panel object. This panel, at design time is empty. When running, I need to create dinamically a Label and a WebControl (built from the same project). I...
4
by: Christian Hofmann | last post by:
Hello, How is it possible to use a hyperlink webcontrol inside a label webcontrol? I am using resources for globalisation. Now I have a text like this: Please click here to open that...
2
by: Peter Rilling | last post by:
Okay, I something weird is happening where I do not know if I am doing something wrong. I have a page that contains a custom webcontrol that I developed. This webcontrol basically loads a...
2
by: Peregrin | last post by:
Hello world. I will try to explain my problem. I've a webcontrol with an interface which provides a choice of methods. After including the webcontrol in a special aspx page, I want to call an...
2
by: Peter van der veen | last post by:
Hi I want to download files from a webserver. Normally a user goes requsta file, files in the login information and gets an "sava as' dialog. I want to automate this. With the use of a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.