dotnetCHARTING Send comments on this topic.
CacheDuration Property
See Also  Example
dotnetCHARTING Namespace > Chart Class : CacheDuration Property


Gets or sets the number of minutes an image is cached and displayed on a page before a new one is generated.

Syntax

Visual Basic (Declaration) 
Public Property CacheDuration As Integer
Visual Basic (Usage)Copy Code
Dim instance As Chart
Dim value As Integer
 
instance.CacheDuration = value
 
value = instance.CacheDuration
C# 
public int CacheDuration {get; set;}

Example

C#Copy Code
//Used the already generated image for upto 45 minutes. 
Chart.CacheDuration = 45; 
    
Visual BasicCopy Code
'Used the already generated image for upto 45 minutes.
Chart.CacheDuration = 45

Remarks

When set, a given chart image will be generated on the first hit and on all subsequent hits within the cache duration period the same image will be returned with no rendering work by the chart control.

See Also