ActiveXLS v6.4.0 API Documentation

ActiveXLS
Class ExcelPageSetup

System.Object
  extended byActiveXLS.ExcelPageSetup

public class ExcelPageSetup
extends System.Object

This class stores page setup settings like print area, the rows to be repeated at top, columns to be repeated at left, page orientation (portrait, landscape), paper size, scaling factor, fit to pages width/height, paper margins, print order, horizontal and vertical page breaks and other customizations like: print gridlines, print black and white, print draft quality, print row and column headings, print comments.


Constructor Summary
ExcelPageSetup(ExcelWorksheet xlsTab)
          Internal use only Defines an instance of page setup.
 
Method Summary
 bool CenterHorizontally()
          Returns the center horizontally option for the page.
 bool CenterVertically()
          Returns the center vertically option for the page.
 System.String esd_getColumnsToRepeatAtLeft()
          Returns the columns to repeat at left.
 System.String esd_getPrintArea()
          Returns the print area.
 System.String esd_getRowsToRepeatAtTop()
          Returns the rows to repeat at top.
 void esd_removePrintArea()
          Removes the print area.
 void esd_setColumnsToRepeatAtLeft(int startColumn, int endColumn)
          Sets the columns to repeat at left.
 void esd_setColumnsToRepeatAtLeft(int startColumn, int endColumn, bool isR1C1ReferenceStyle)
          Sets the columns to repeat at left.
 void esd_setColumnsToRepeatAtLeft(System.String columnRange)
          Sets the columns to repeat at left.
 void esd_setPrintArea(int startRow, int startColumn, int endRow, int endColumn)
          Sets the print area.
 void esd_setPrintArea(int startRow, int startColumn, int endRow, int endColumn, bool isR1C1ReferenceStyle)
          Sets the print area.
 void esd_setPrintArea(System.String range)
          Sets the print area.
 void esd_setRowsToRepeatAtTop(int startRow, int endRow)
          Sets the rows to repeat at top.
 void esd_setRowsToRepeatAtTop(int startRow, int endRow, bool isR1C1ReferenceStyle)
          Sets the rows to repeat at top.
 void esd_setRowsToRepeatAtTop(System.String rowRange)
          Sets the rows to repeat at top.
 double getBottomMargin()
          Returns the bottom margin of the paper.
 int getFirstPageNumber()
          Returns the starting page number.
 int getFitToPagesHeight()
          Returns the number of pages to fit in the page height.
 int getFitToPagesWidth()
          Returns the number of pages to fit in the page width.
 double getFooterMargin()
          Returns the footer margin of the paper.
 double getHeaderMargin()
          Returns the header margin of the paper.
 double getLeftMargin()
          Returns the left margin of the paper.
 System.String getOrientation()
          Returns the page orientation.
 int getPageOrder()
          Returns the print page order.
 int getPaperSize()
          Returns the paper size.
 System.String getPrintArea()
          Internal use only
 int getPrintComments()
          Returns the print comments option for the page.
 double getRightMargin()
          Returns the right margin of the paper.
 int getScalingFactor()
          Returns the scaling factor.
 double getTopMargin()
          Returns the top margin of the paper.
 bool PrintBlackAndWhite()
          Returns the print black and white option for the page.
 bool PrintDraftQuality()
          Returns the print draft quality option for the page.
 bool PrintGridlines()
          Returns the print gridlines option for the page.
 bool PrintRowAndColumnHeadings()
          Returns the print row and column headings option for the page.
 void setBottomMargin(double bottomMargin)
          Sets the bottom margin of the paper.
 void setCenterHorizontally(bool isCenterHorizontally)
          Sets the center horizontally option for the page.
 void setCenterVertically(bool isCenterVertically)
          Sets the center vertically option for the page.
 void setFirstPageNumber(int firstPageNumber)
          Sets the starting page number.
 void setFitToPagesHeight(int value)
          Sets the number of pages to fit in the page height.
 void setFitToPagesWidth(int value)
          Sets the number of pages to fit in the page width.
 void setFooterMargin(double footerMargin)
          Sets the footer margin of the paper.
 void setHeaderMargin(double headerMargin)
          Sets the header margin of the paper.
 void setLeftMargin(double leftMargin)
          Sets the left margin of the paper.
 void setOrientation(System.String orientation)
          Sets the page orientation.
 void setPageOrder(int pageOrder)
          Sets the print page order.
 void setPaperSize(int paperSize)
          Sets the paper size.
 void setPrintBlackAndWhite(bool printBlackAndWhite)
          Sets the print black and white option for the page.
 void setPrintComments(int position)
          Sets the print comments option for the page.
 void setPrintDraftQuality(bool printDraftQuality)
          Sets the print draft quality option for the page.
 void setPrintGridlines(bool printGridlines)
          Sets the print gridlines option for the page.
 void setPrintRowAndColumnHeadings(bool printRowAndColumnHeadings)
          Sets the print row and column headings option for the page.
 void setRightMargin(double rightMargin)
          Sets the right margin of the paper.
 void setScalingFactor(int scalingFactor)
          Sets the scaling factor.
 void setTopMargin(double topMargin)
          Sets the top margin of the paper.
 

Constructor Detail

ExcelPageSetup

public ExcelPageSetup(ExcelWorksheet xlsTab)
Internal use only Defines an instance of page setup. The settings belong to the specified worksheet.

Parameters:
xlsTab - - the worksheet that has these settings.
Method Detail

esd_setPrintArea

public void esd_setPrintArea(int startRow,
                             int startColumn,
                             int endRow,
                             int endColumn,
                             bool isR1C1ReferenceStyle)
Sets the print area.

Parameters:
startRow - the start row of the range that defines the print area
startColumn - the start column of the range that defines the print area
endRow - the end row of the range that defines the print area
endColumn - the end column of the range that defines the print area
isR1C1ReferenceStyle - the R1C1 reference style of the document
See Also:
esd_setPrintArea(String), esd_getPrintArea(), esd_removePrintArea()

esd_setPrintArea

public void esd_setPrintArea(int startRow,
                             int startColumn,
                             int endRow,
                             int endColumn)
Sets the print area. You should use this method only if the ExcelDocument R1C1 style reference flag is set to true.

Parameters:
startRow - the start row of the range that defines the print area
startColumn - the start column of the range that defines the print area
endRow - the end row of the range that defines the print area
endColumn - the end column of the range that defines the print area
See Also:
esd_setPrintArea(String), esd_getPrintArea(), esd_removePrintArea()

esd_setPrintArea

public void esd_setPrintArea(System.String range)
Sets the print area.

Parameters:
range - the print area. It can be a cell reference or a range.
See Also:
esd_setPrintArea(int,int,int,int), esd_getPrintArea(), esd_removePrintArea()

esd_getPrintArea

public System.String esd_getPrintArea()
Returns the print area. It can be a cell reference or a cell range.

Returns:
the print area
See Also:
esd_setPrintArea(int,int,int,int), esd_setPrintArea(String), esd_removePrintArea()

getPrintArea

public System.String getPrintArea()
Internal use only


esd_removePrintArea

public void esd_removePrintArea()
Removes the print area.

See Also:
esd_setPrintArea(int,int,int,int), esd_setPrintArea(String), esd_getPrintArea()

esd_setRowsToRepeatAtTop

public void esd_setRowsToRepeatAtTop(int startRow,
                                     int endRow,
                                     bool isR1C1ReferenceStyle)
Sets the rows to repeat at top.

Parameters:
startRow - - first row index of the row range
endRow - - last row index of the row range
isR1C1ReferenceStyle - the R1C1 reference style of the document
See Also:
esd_getRowsToRepeatAtTop(), esd_setColumnsToRepeatAtLeft(int, int, bool), esd_getColumnsToRepeatAtLeft()

esd_setRowsToRepeatAtTop

public void esd_setRowsToRepeatAtTop(int startRow,
                                     int endRow)
Sets the rows to repeat at top. You should use this method only if the ExcelDocument R1C1 style reference flag is set to true.

Parameters:
startRow - - first row index of the row range
endRow - - last row index of the row range
See Also:
esd_getRowsToRepeatAtTop(), esd_setColumnsToRepeatAtLeft(int, int, bool), esd_getColumnsToRepeatAtLeft()

esd_setRowsToRepeatAtTop

public void esd_setRowsToRepeatAtTop(System.String rowRange)
Sets the rows to repeat at top.

Parameters:
rowRange - - a row range that defines the rows to repeat at top (like "$1:$2")
See Also:
esd_getRowsToRepeatAtTop(), esd_setColumnsToRepeatAtLeft(int, int, bool), esd_getColumnsToRepeatAtLeft()

esd_getRowsToRepeatAtTop

public System.String esd_getRowsToRepeatAtTop()
Returns the rows to repeat at top.

Returns:
a row range representing the rows to repeat at top
See Also:
esd_setRowsToRepeatAtTop(int, int, bool), esd_setColumnsToRepeatAtLeft(int, int, bool), esd_getColumnsToRepeatAtLeft()

esd_getColumnsToRepeatAtLeft

public System.String esd_getColumnsToRepeatAtLeft()
Returns the columns to repeat at left.

Returns:
a column range representing the columns to repeat at left
See Also:
esd_setColumnsToRepeatAtLeft(int, int, bool), esd_setRowsToRepeatAtTop(int, int, bool), esd_getRowsToRepeatAtTop()

esd_setColumnsToRepeatAtLeft

public void esd_setColumnsToRepeatAtLeft(int startColumn,
                                         int endColumn,
                                         bool isR1C1ReferenceStyle)
Sets the columns to repeat at left.

Parameters:
startColumn - - first column index of the column range
endColumn - - last column index of the column range
isR1C1ReferenceStyle - the R1C1 reference style of the document
See Also:
esd_getColumnsToRepeatAtLeft(), esd_setRowsToRepeatAtTop(int, int, bool), esd_getRowsToRepeatAtTop()

esd_setColumnsToRepeatAtLeft

public void esd_setColumnsToRepeatAtLeft(int startColumn,
                                         int endColumn)
Sets the columns to repeat at left. You should use this method only if the ExcelDocument R1C1 style reference flag is set to true.

Parameters:
startColumn - - first column index of the column range
endColumn - - last column index of the column range
See Also:
esd_getColumnsToRepeatAtLeft(), esd_setRowsToRepeatAtTop(int, int, bool), esd_getRowsToRepeatAtTop()

esd_setColumnsToRepeatAtLeft

public void esd_setColumnsToRepeatAtLeft(System.String columnRange)
Sets the columns to repeat at left.

Parameters:
columnRange - - a column range that defines the columns to repeat at left (like "$A:$B")
See Also:
esd_getColumnsToRepeatAtLeft(), esd_setRowsToRepeatAtTop(int, int, bool), esd_getRowsToRepeatAtTop()

getOrientation

public System.String getOrientation()
Returns the page orientation. Possible values are available in PageSetup class.

Returns:
the page orientation
See Also:
setOrientation(System.String)

setOrientation

public void setOrientation(System.String orientation)
Sets the page orientation. Possible values are available in PageSetup class.

Parameters:
orientation - the page orientation
See Also:
getOrientation()

getPaperSize

public int getPaperSize()
Returns the paper size. Possible values are available in PageSetup class.

Returns:
the paper size
See Also:
setPaperSize(int)

setPaperSize

public void setPaperSize(int paperSize)
Sets the paper size. Possible values are available in PageSetup class.

Parameters:
paperSize - the paper size
See Also:
getPaperSize()

getScalingFactor

public int getScalingFactor()
Returns the scaling factor.

Returns:
the scaling factor
See Also:
setScalingFactor(int)

setScalingFactor

public void setScalingFactor(int scalingFactor)
Sets the scaling factor.

Parameters:
scalingFactor - the scaling factor
See Also:
getScalingFactor()

getFitToPagesWidth

public int getFitToPagesWidth()
Returns the number of pages to fit in the page width.

Returns:
the number of pages to fit in the page width
See Also:
setFitToPagesWidth(int), getFitToPagesHeight(), setFitToPagesHeight(int)

setFitToPagesWidth

public void setFitToPagesWidth(int value)
Sets the number of pages to fit in the page width.

Parameters:
value - the number of pages to fit in the page width
See Also:
getFitToPagesWidth(), getFitToPagesHeight(), setFitToPagesHeight(int)

getFitToPagesHeight

public int getFitToPagesHeight()
Returns the number of pages to fit in the page height.

Returns:
the number of pages to fit in the page height
See Also:
setFitToPagesHeight(int), getFitToPagesWidth(), setFitToPagesWidth(int)

setFitToPagesHeight

public void setFitToPagesHeight(int value)
Sets the number of pages to fit in the page height.

Parameters:
value - the number of pages to fit in the page height
See Also:
getFitToPagesHeight(), getFitToPagesWidth(), setFitToPagesWidth(int)

getFirstPageNumber

public int getFirstPageNumber()
Returns the starting page number.

Returns:
the starting page number
See Also:
setFirstPageNumber(int)

setFirstPageNumber

public void setFirstPageNumber(int firstPageNumber)
Sets the starting page number.

Parameters:
firstPageNumber - the starting page number
See Also:
getFirstPageNumber()

getTopMargin

public double getTopMargin()
Returns the top margin of the paper.

Returns:
the top margin of the paper
See Also:
setTopMargin(double), getBottomMargin(), getLeftMargin(), getRightMargin()

setTopMargin

public void setTopMargin(double topMargin)
Sets the top margin of the paper.

Parameters:
topMargin - the top margin of the paper
See Also:
getTopMargin(), setBottomMargin(double), setLeftMargin(double), setRightMargin(double)

getBottomMargin

public double getBottomMargin()
Returns the bottom margin of the paper.

Returns:
the bottom margin of the paper
See Also:
setBottomMargin(double), getTopMargin(), getLeftMargin(), getRightMargin()

setBottomMargin

public void setBottomMargin(double bottomMargin)
Sets the bottom margin of the paper.

Parameters:
bottomMargin - the bottom margin of the paper
See Also:
getBottomMargin(), setTopMargin(double), setLeftMargin(double), setRightMargin(double)

getLeftMargin

public double getLeftMargin()
Returns the left margin of the paper.

Returns:
the left margin of the paper
See Also:
setLeftMargin(double), getTopMargin(), getBottomMargin(), getRightMargin()

setLeftMargin

public void setLeftMargin(double leftMargin)
Sets the left margin of the paper.

Parameters:
leftMargin - the left margin of the paper
See Also:
getLeftMargin(), setTopMargin(double), setBottomMargin(double), setRightMargin(double)

getRightMargin

public double getRightMargin()
Returns the right margin of the paper.

Returns:
the right margin of the paper
See Also:
setRightMargin(double), getTopMargin(), getBottomMargin(), getLeftMargin()

setRightMargin

public void setRightMargin(double rightMargin)
Sets the right margin of the paper.

Parameters:
rightMargin - the right margin of the paper
See Also:
getRightMargin(), setTopMargin(double), setBottomMargin(double), setLeftMargin(double)

getHeaderMargin

public double getHeaderMargin()
Returns the header margin of the paper.

Returns:
the header margin of the paper
See Also:
setHeaderMargin(double), getFooterMargin()

setHeaderMargin

public void setHeaderMargin(double headerMargin)
Sets the header margin of the paper.

Parameters:
headerMargin - the header margin of the paper
See Also:
getHeaderMargin(), setFooterMargin(double)

getFooterMargin

public double getFooterMargin()
Returns the footer margin of the paper.

Returns:
the footer margin of the paper
See Also:
setFooterMargin(double), getHeaderMargin()

setFooterMargin

public void setFooterMargin(double footerMargin)
Sets the footer margin of the paper.

Parameters:
footerMargin - the footer margin of the paper
See Also:
getFooterMargin(), setHeaderMargin(double)

CenterHorizontally

public bool CenterHorizontally()
Returns the center horizontally option for the page.

Returns:
the center horizontally option for the page
See Also:
setCenterHorizontally(bool), CenterVertically(), setCenterVertically(bool)

setCenterHorizontally

public void setCenterHorizontally(bool isCenterHorizontally)
Sets the center horizontally option for the page.

Parameters:
isCenterHorizontally - the center horizontally option for the page
See Also:
CenterHorizontally(), CenterVertically(), setCenterVertically(bool)

CenterVertically

public bool CenterVertically()
Returns the center vertically option for the page.

Returns:
the center vertically option for the page
See Also:
setCenterVertically(bool), CenterHorizontally(), setCenterHorizontally(bool)

setCenterVertically

public void setCenterVertically(bool isCenterVertically)
Sets the center vertically option for the page.

Parameters:
isCenterVertically - the center vertically option for the page
See Also:
CenterVertically(), CenterHorizontally(), setCenterHorizontally(bool)

PrintGridlines

public bool PrintGridlines()
Returns the print gridlines option for the page.

Returns:
the print gridlines option for the page
See Also:
setPrintGridlines(bool)

setPrintGridlines

public void setPrintGridlines(bool printGridlines)
Sets the print gridlines option for the page.

Parameters:
printGridlines - the print gridlines option for the page
See Also:
PrintGridlines()

PrintBlackAndWhite

public bool PrintBlackAndWhite()
Returns the print black and white option for the page.

Returns:
the print black and white option for the page
See Also:
setPrintBlackAndWhite(bool)

setPrintBlackAndWhite

public void setPrintBlackAndWhite(bool printBlackAndWhite)
Sets the print black and white option for the page.

Parameters:
printBlackAndWhite - the print black and white option for the page
See Also:
PrintBlackAndWhite()

PrintDraftQuality

public bool PrintDraftQuality()
Returns the print draft quality option for the page.

Returns:
the print draft quality option for the page
See Also:
setPrintDraftQuality(bool)

setPrintDraftQuality

public void setPrintDraftQuality(bool printDraftQuality)
Sets the print draft quality option for the page.

Parameters:
printDraftQuality - the print draft quality option for the page
See Also:
PrintDraftQuality()

PrintRowAndColumnHeadings

public bool PrintRowAndColumnHeadings()
Returns the print row and column headings option for the page.

Returns:
the print row and column headings option for the page
See Also:
setPrintRowAndColumnHeadings(bool)

setPrintRowAndColumnHeadings

public void setPrintRowAndColumnHeadings(bool printRowAndColumnHeadings)
Sets the print row and column headings option for the page.

Parameters:
printRowAndColumnHeadings - the print row and column headings option for the page
See Also:
PrintRowAndColumnHeadings()

getPrintComments

public int getPrintComments()
Returns the print comments option for the page. Possible values are available in PageSetup class.

Returns:
the print comments option for the page
See Also:
setPrintComments(int)

setPrintComments

public void setPrintComments(int position)
Sets the print comments option for the page. Possible values are available in PageSetup class.

Parameters:
position - the print comments option for the page
See Also:
getPrintComments()

getPageOrder

public int getPageOrder()
Returns the print page order. Possible values are available in PageSetup class.

Returns:
the print page order
See Also:
setPageOrder(int)

setPageOrder

public void setPageOrder(int pageOrder)
Sets the print page order. Possible values are available in PageSetup class.

Parameters:
pageOrder - the print page order
See Also:
getPageOrder()

Copyright 2009 On Time Computing Solutions