[]
Represents a picture embedded in a cell (Picture-In-Cell).
public class CellPicture
Public Class CellPicture
byte[] imageBytes = System.Convert.FromBase64String(
"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8/x8AAwMCAO+aF9sAAAAASUVORK5CYII=");
CellPicture picture = new CellPicture(imageBytes, "Company logo");
worksheet.Range["A1"].CellPicture = picture;
CellPicture savedPicture = worksheet.Range["A1"].CellPicture;
string altText = savedPicture.AltText;
| Name | Description |
|---|---|
| CellPicture(byte[]) | Initializes a new instance of the CellPicture class with the specified image data. The provided array is copied, so subsequent changes to the input array do not affect this instance. |
| CellPicture(byte[], string) | Initializes a new instance of the CellPicture class with the specified image data and alt text. The provided array is copied, so subsequent changes to the input array do not affect this instance. |
| Name | Description |
|---|---|
| AltText | Gets or sets the alt text of the picture. The alt text is also used as the display value for Filter and Sort. After modification, it must be reassigned to CellPicture to take effect. |
| ImageData | Gets a copy of the image binary data. |