Input for WinForms | ComponentOne
C1.Framework Namespace / Theme Class / SaveImage Method
System.Xml.XmlWriter that contains the theme definition.
Name of the node where the image will be stored.
System.Drawing.Image that will be saved in the stream.

In This Topic
    SaveImage Method (Theme)
    In This Topic
    Saves an image into the Xml output stream.
    Syntax
    'Declaration
     
    
    Protected Overridable Sub SaveImage( _
       ByVal writer As XmlWriter, _
       ByVal propertyName As String, _
       ByVal image As Image _
    ) 
    protected virtual void SaveImage( 
       XmlWriter writer,
       string propertyName,
       Image image
    )

    Parameters

    writer
    System.Xml.XmlWriter that contains the theme definition.
    propertyName
    Name of the node where the image will be stored.
    image
    System.Drawing.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"/]
    See Also