ExcelPicture Class
Represents a picture in the worksheet.
public sealed class ExcelPicture : ExcelDrawing
Public NotInheritable Class ExcelPicture
Inherits ExcelDrawing
- Inheritance:
- ExcelPicture
Properties
PictureFormat
Gets the picture format.
public ExcelPictureFormat PictureFormat { get; }
Public ReadOnly Property PictureFormat As ExcelPictureFormat
Property Value
The picture format.
PictureStream
Gets the picture stream.
public MemoryStream PictureStream { get; }
Public ReadOnly Property PictureStream As MemoryStream
Property Value
The picture stream.
Transparency
Gets or sets the transparency of the picture. Possible values range from 0 (full transparency) to 1 (no transparency). The default value is 1 (no transparency).
Property Value
- System.Double
The transparency of the picture.
TransparentColor
Gets or sets the transparent color in the image. By default, no transparent color is set.
public SpreadsheetColor? TransparentColor { get; set; }
Public Property TransparentColor As SpreadsheetColor?
Property Value
The transparent color in the image.
Methods
Delete()
Removes this ExcelPicture instance from the worksheet.
ToImage()
Converts this ExcelPicture instance to a new Image instance.
Returns
A new Image instance created from this ExcelPicture instance.
ToString()
Returns a System.String that represents this ExcelPicture instance.
Returns
- System.String
A System.String that represents this ExcelPicture instance.
Overrides
Remarks
This method should be used primarily for debugging purposes and should be considered volatile (format of its return value might change in future versions).
Inherited Properties
Hyperlink | Gets or sets the hyperlink on this drawing (picture, chart, etc.). (Inherited from ExcelDrawing) |
Metadata | Gets the metadata (non-visual properties) of this ExcelDrawing instance. (Inherited from ExcelDrawing) |
Position | Gets the position of this drawing (picture, chart, etc.) in the worksheet. (Inherited from ExcelDrawing) |
Worksheet | Gets the parent worksheet. (Inherited from ExcelDrawing) |
Inherited Methods
Format() | Formats this drawing (picture, chart, etc.) to its default size so it can be exported to PDF, XPS, image or be printed. (Inherited from ExcelDrawing) |
Format(System.Double, System.Double, LengthUnit) | Formats this drawing (picture, chart, etc.) to specified size so it can be exported to PDF, XPS, image or be printed. (Inherited from ExcelDrawing) |