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


Gets or sets a value indicating whether the generated image is saved
temporarily in a session variable for subsequent streaming from a helper aspx page. This option may only be used when UseFile = false.

Syntax

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

Example

C#Copy Code
Chart.UseSession = true; 
    
Visual BasicCopy Code
Chart.UseSession = true

Remarks

.netCHARTING supports streaming images directly to the browser in addition
to returning a reference to a generated image file. There are differences in
the way the control can be used between these two image return methods. When using a file reference, you are free to treat the page as you normally would, and include HTML and any other web content on the page.<br/>

Since streaming turns the page you include the control on into the actual
image file return, the browser will not also allow HTML within the same http
request. As a result url, tooltip and drilldown options will not be
enabled. Setting UseSession to true works around this issue by returning an
image reference to a separate aspx page for image streaming. The image
stream is temporary stored in a session variable and an aspx page in the
temp directory streams the image to the browser, enabling the regular HTML
and image map based features to work seamlessly with the control.

NOTE: streaming of any kind (direct or through the session helper) has a large performance cost over the file based system which has build in cleanup functionlity and should be used in all possible environments. Streaming
should never be used unless your environment completely prevents write
access which is required for the file based system to operate.<br/>

See Also