[]
        
(Showing Draft Content)

C1.Framework.Theme.SaveImage

SaveImage Method

SaveImage(XmlWriter, string, Image)

Saves an image into the Xml output stream.

Declaration
protected virtual void SaveImage(XmlWriter writer, string propertyName, Image image)
Parameters
Type Name Description
XmlWriter writer

XmlWriter that contains the theme definition.

string propertyName

Name of the node where the image will be stored.

Image image

Image that will be saved in the stream.

Remarks

The default implementation keeps a list of the images that have been saved. If any images are saved more than once, only the index is stored for the repeated instances.

For example:

SaveImage(writer, "MyImageProperty", img);
SaveImage(writer, "MyImagePropertyAgain", img);
SaveImage(writer, "MyImagePropertyAndAgain", img);

[MyImageProperty]base64data[/MyImageProperty]
[MyImagePropertyAgain index="0"/]
[MyImagePropertyAndAgain index="0"/]