I have an Excel document which contains some pictures. I want to use Aspose.Cells to extract a picture from excel, but I found that the extracted picture is a thumbnail, not the original picture.
void Main()
{
string filePath = @"C:\Users\54390\Downloads\2022年最美评选-c4403bd51c9d4847ba489a6077513472.xlsx";
var workbook = new Aspose.Cells.Workbook(filePath);
var pictureList = new List<Aspose.Cells.Drawing.Picture>();
pictureList.AddRange(workbook.Worksheets[0].Pictures);
foreach(var picture in pictureList){
picture.Width.Dump();
picture.Height.Dump();
}
}
Version info:
Aspose.Cells for Net 23.1.1
The demo file:
2022年最美评选-c4403bd51c9d4847ba489a6077513472.zip (1.8 MB)
The screenshot:
20230301220744.png (20.1 KB)
I entered the resource directory of this Excel file and found that the width and height of the original picture are actually very large.
20230301221131.png (56.6 KB)