ChartDirector 7.1 (.NET Edition)

RazorChartViewer.ContentDisposition


Declaration

[C#]public string ContentDisposition {get; set;};
[VB]Public Property ContentDisposition As String

Description

The suggested filename to use when user saves the chart image as a file on the browser side.

When the user right click on a image in a web page, and select "Save Image As" (or doing something similar depending on the browser), the browser will derived a filename from the image URL. This works well if the URL is an image file. However, for dynamically created images, the URL is often a script with an non-image extension such as ".aspx". Also, the same URL can be used to create different images. If the filename is derived from the URL, it may use extensions not appropriate for images (some browsers will automatically adjust the extension to the image type), different images may end up having the same filename, and the filename may not reflect the nature of the image.

To address these issues, the ContentDisposition can be used to suggest a filename. The browser should then use the suggested filename instead of deriving it from the URL. This allows a more meaningful filename to be used which better reflects the nature of the image.