Click or drag to resize
ExcelPictureCollectionAdd Method (MemoryStream, ExcelPictureFormat, AnchorCell, AnchorCell)
Adds a new picture to the worksheet which moves and sizes with cells.

Namespace: GemBox.Spreadsheet
Assembly: GemBox.Spreadsheet (in GemBox.Spreadsheet.dll) Version: 39.3.30.1198
Syntax
public ExcelPicture Add(
	MemoryStream pictureStream,
	ExcelPictureFormat pictureFormat,
	AnchorCell positionFrom,
	AnchorCell positionTo
)

Parameters

pictureStream
Type: System.IOMemoryStream
The picture's stream.
pictureFormat
Type: GemBox.SpreadsheetExcelPictureFormat
The picture's format.
positionFrom
Type: GemBox.SpreadsheetAnchorCell
The picture's position (top-left corner).
positionTo
Type: GemBox.SpreadsheetAnchorCell
The picture's end position (bottom-right corner).

Return Value

Type: ExcelPicture
A new picture added to the worksheet which moves and sizes with cells.
Remarks
Position.Mode of a newly added picture will be MoveAndSize.
See Also