java.lang.Object
com.aspose.cells.SheetRender
public class SheetRender
- extends java.lang.Object
Represents a worksheet render which can render worksheet to various images such as (BMP, PNG, JPEG, TIFF..)
The constructor of this class , must be used after modification of pagesetup, cell style.
Property Getters/Setters Summary |
int | getPageCount() | |
void | setPageCount(int value) | |
|
Indicate the total page count of current worksheet
|
Method Summary |
java.awt.Dimension | getPageSize(int pageIndex) | |
Get page size of output image. The size unit is in pixel.
|
void | toImage(int pageIndex, java.io.OutputStream stream) | |
Render certain page to a stream.
|
void | toImage(int pageIndex, java.lang.String fileName) | |
Render certain page to a file.
|
void | toPrinter(java.lang.String PrinterName) | |
Render worksheet to Printer
|
SheetRender
public SheetRender(Worksheet worksheet, ImageOrPrintOptions options)
throws java.lang.Exception
-
the construct of SheetRender, need worksheet and ImageOrPrintOptions as params
- Parameters:
worksheet
- Indicate which spreadsheet to be rendered.options
- ImageOrPrintOptions contains some property of output image
Property Getters/Setters Detail |
getPageCount/setPageCount | |
public int getPageCount() / public void setPageCount(int value)
|
-
Indicate the total page count of current worksheet
getPageSize | |
public java.awt.Dimension getPageSize(int pageIndex) |
-
Get page size of output image. The size unit is in pixel.
- Parameters:
pageIndex
- The page index is based on zero.
- Returns:
toImage | |
public void toImage(int pageIndex, java.lang.String fileName)
throws java.lang.Exception |
-
Render certain page to a file.
- Parameters:
pageIndex
- indicate which page is to be convertedfileName
- filename of the output image
toImage | |
public void toImage(int pageIndex, java.io.OutputStream stream)
throws java.lang.Exception |
-
Render certain page to a stream.
- Parameters:
pageIndex
- indicate which page is to be convertedstream
- the stream of the output image
toPrinter | |
public void toPrinter(java.lang.String PrinterName)
throws java.lang.Exception |
-
Render worksheet to Printer
- Parameters:
PrinterName
- the name of the printer , for example: "Microsoft Office Document Image Writer"
See Also:
Aspose.Cells Documentation - the home page for the Aspose.Cellss Product Documentation.
Aspose.Cells Support Forum - our preferred method of support.