Conversion d'une feuille de calcul en fichier image par page

 Workbook book = new Workbook("Feuille à Image par Page.xls");

Feuille de calcul = livre. Feuilles de travail [0] ;

Aspose.Cells.Rendering.ImageOrPrintOptions options = nouveau Aspose.Cells.Rendering.ImageOrPrintOptions();

options.HorizontalResolution = 200;

options.VerticalResolution = 200;

options.ImageFormat = System.Drawing.Imaging.ImageFormat.Tiff ;

// Conversion Sheet2Image par page

SheetRender sr = new SheetRender(feuille, options);

 pour (int j = 0; j< sr.PageCount; j++)

{

	Bitmap pic = sr.ToImage(j);

	pic.Save(sheet.Name + " Page" + (j + 1) + ".tiff");

}

Télécharger l’exemple de code