-
com.grapecity.documents.excel
-
- EventHandler
- IAboveAverage
- IAreas
- IAuthor
- IAutoCorrect
- IAutoFilter
- IAutoMergeRangeInfo
- IBarcode
- IBorder
- IBorders
- IBuiltInDocumentPropertyCollection
- ICalcContext
- ICalculatedFields
- ICalculatedItems
- ICascadeSparkLine
- ICellCollection
- ICellColorSortField
- ICellDecoration
- ICellDecorationIcon
- ICellPadding
- ICodabar
- ICode128
- ICode39
- ICode49
- ICode93
- IColorScale
- IColorScaleCriteria
- IColorScaleCriterion
- IColorStop
- IColorStops
- IComment
- IComments
- ICommentsThreaded
- ICommentThreaded
- IConditionValue
- ICornerFold
- ICsvParser
- ICustomDocumentPropertyCollection
- ICustomView
- ICustomViews
- IDataBar
- IDataBarBorder
- IDataMatrix
- IDataOptions
- IDisplayFormat
- IDocumentProperty
- IDocumentPropertyCollection
- IEAN13
- IEAN8
- IExcelOptions
- IFilter
- IFilters
- IFont
- IFontColorSortField
- IFontOption
- IFontProvider
- IFormatColor
- IFormatCondition
- IFormatConditions
- IFormulaOptions
- IFormulaResolver
- IGraphic
- IGraphicsInfo
- IGroupInfo
- IGS1128
- IHeaderFooter
- IHPageBreak
- IHPageBreaks
- IHyperlink
- IHyperlinks
- IIcon
- IIconCriteria
- IIconCriterion
- IIconSet
- IIconSetCondition
- IIconSets
- IIconSortField
- IInterior
- IJsonSerializer
- ILabelOption
- ILabelOptions
- ILinearGradient
- IName
- INames
- INegativeBarFormat
- IOutline
- IOutlineColumn
- IPage
- IPageSetup
- IPane
- IPanes
- IPDF417
- IPDFRenderEngine
- IPivotAxis
- IPivotCache
- IPivotCaches
- IPivotCell
- IPivotField
- IPivotFields
- IPivotFilter
- IPivotFilters
- IPivotFormula
- IPivotFormulas
- IPivotItem
- IPivotItemList
- IPivotItems
- IPivotLine
- IPivotLineCells
- IPivotLines
- IPivotTable
- IPivotTables
- IPivotValueCell
- IProtectionSettings
- IQRCode
- IRange
- IRangeProvider
- IReadOnlySignatureDetails
- IRectangularGradient
- IRichText
- IScenario
- IScenarios
- ISheetTab
- ISheetTabs
- IShrinkToFitSettings
- ISignature
- ISignatureSet
- ISignatureSetup
- ISlicer
- ISlicerCache
- ISlicerCaches
- ISlicerItem
- ISlicerItems
- ISlicerPivotTables
- ISlicers
- ISort
- ISortField
- ISortFields
- ISparkAxes
- ISparkColor
- ISparkHorizontalAxis
- ISparkline
- ISparklineGroup
- ISparklineGroups
- ISparkLineObject
- ISparkPoints
- ISparkVerticalAxis
- IStyle
- IStyleCollection
- ITable
- ITableColumn
- ITableColumns
- ITableDataSource
- ITableRow
- ITableRows
- ITables
- ITableStyle
- ITableStyleCollection
- ITableStyleElement
- ITableStyleElements
- ITableStyleInfo
- ITextRun
- ITheme
- IThemeColor
- IThemeColorScheme
- IThemeFont
- IThemeFonts
- IThemeFontScheme
- ITop10
- IUniqueValues
- IValidation
- IValueSortField
- IVPageBreak
- IVPageBreaks
- IWebRequestHandler
- IWorkbook
- IWorkbookView
- IWorksheet
- IWorksheets
- IWorksheetView
- RangeFindReplace.FindReplaceImpl.FindMatch
- RangePartialClasses.FindReplaceImpl.FindMatch
-
- com.grapecity.documents.excel.drawing
- com.grapecity.documents.excel.expressions
- com.grapecity.documents.excel.forms
- com.grapecity.documents.excel.template
- com.grapecity.documents.excel.template.DataSource
IRange
Interface IRange
-
Method Summary
Modifier and TypeMethodDescriptionvoidactivate()Activates a single cell, which must be inside the current selection.addComment(String text) Adds comments to the current range.addCommentThreaded(String text) Adds a threaded comment to the range.addCommentThreaded(String text, String author) Adds a threaded comment to the range.voidFilters a list using the AutoFilter.
Add a filter with no condition if there's no filter in the sheet.
Or show all the data in the first column of the filter.voidautoFilter(boolean isFirstRowData) Filters a list using the AutoFilter.
Add a filter with no condition if there's no filter in the sheet.
Or show all the data in the first column of the filter.voidautoFilter(boolean isFirstRowData, int field) Filters a list using the AutoFilter.voidautoFilter(boolean isFirstRowData, int field, Object criteria1) Filters a list using the AutoFilter.voidautoFilter(boolean isFirstRowData, int field, Object criteria1, AutoFilterOperator op) Filters a list using the AutoFilter.voidautoFilter(boolean isFirstRowData, int field, Object criteria1, AutoFilterOperator op, Object criteria2) Filters a list using the AutoFilter.voidautoFilter(boolean isFirstRowData, int field, Object criteria1, AutoFilterOperator op, Object criteria2, boolean visibleDropDown) Filters a list using the AutoFilter.voidautoFilter(int field) Filters a list using the AutoFilter.voidautoFilter(int field, Object criteria1) Filters a list using the AutoFilter.voidautoFilter(int field, Object criteria1, AutoFilterOperator op) Filters a list using the AutoFilter.voidautoFilter(int field, Object criteria1, AutoFilterOperator op, Object criteria2) Filters a list using the AutoFilter.voidautoFilter(int field, Object criteria1, AutoFilterOperator op, Object criteria2, boolean visibleDropDown) Filters a list using the AutoFilter.voidautoFit()Changes the width of the columns in the range or the height of the rows in the range to achieve the best fit.voidautoFit(boolean considerMergedCell) Changes the width of the columns in the range or the height of the rows in the range to achieve the best fit.voidCalculates formulas of the range as needed.characters(int startIndex, int length) Returns a ITextRun object that represents a range of characters within the cell text.voidclear()Clears formulas, values, and all formatting from the current range.voidClears the comments from the current rangevoidClears the threaded comments from the current range.voidClears formulas and values from the current range.voidClears all formatting from the current range.voidClears all hyperLinks from the current range.voidClears the outline for the specified range.voidCopies the range to the specified rangevoidcopy(IRange destination, PasteOption pasteOption) Copies the range to the specified range.voidDeprecated.This method is no longer acceptable to compute time between versions.voidCuts the range to the specified range.voiddelete()Deletes a cell or a range of cells from the worksheet and shifts other cells to replace deleted cells.voiddelete(DeleteShiftDirection shiftDirection) Deletes a cell or a range of cells from the worksheet and shifts other cells to replace deleted cells.voiddirty()Designates all the formulas of the range to be recalculated when the next calculation occurs.Finds specific information in a range, starts from the upper-left corner.find(Object what, FindOptions options) Finds specific information in a range, starts from the upper-left corner.Finds specific information in a range.find(Object what, IRange after, FindOptions options) Finds specific information in a range.voidGenerates the range data from the json string.Generate the corresponding function "GETPIVOTDATA" for the cells in the pivot table.generateGetPivotDataFunction(IRange destination) Generate the corresponding function "GETPIVOTDATA" for the cells in the pivot table.get(int index) Returns a new instance ofIRangeby index which represents a cell.get(int rowOffset, int columnOffset) Returns a new instance ofIRangewhich is offset from this range.booleanGets the property which controls indentation of text when horizontal or vertical alignment is set to distributed.Returns a String value that represents the range reference.getAddress(boolean rowAbsolute, boolean columnAbsolute) Returns a String value that represents the range reference.getAddress(boolean rowAbsolute, boolean columnAbsolute, ReferenceStyle referenceStyle) Returns a String value that represents the range reference.getAddress(boolean rowAbsolute, boolean columnAbsolute, ReferenceStyle referenceStyle, IRange relativeTo) Returns a String value that represents the range reference.getAreas()Returns an instance ofIAreaswhich represents an array of rangeswhere each range returned by areas represents one cell or range.byte[]Gets the cell background image.Gets the cell background image layout, default is Stretch.Gets the binding path of the current cell or column.Returns an instance ofIBorderswhich represents the cell borders ofthe cell or range represented by this IRange.Gets the cell padding for range.getCells()Returns theIRangeobject that represents the cells in the specifiedrange.Gets the cell type for specified range in the sheet.intReturns the zero based column number of the first column of this IRange.intReturns the column count of the first range.Returns theIRangeobject that represents the columns in thespecified range.doubleGets the width of the individual columns represented in this range in characters.doubleGets the width of the individual columns represented in this range in pixels.Returns an instance ofICommentwhich may be used to get and setComment properties of the cells.intgetCount()Returns the number of objects in the collection.Gets whether the specified cell is part of an array, returns anIRangeobject that represents the entire array.Gets the cell decoration for range.Gets the default value of the cell, it can be the value data or the formula string.Gets the dependent ranges of the left top cell of the range.getDependents(boolean includeIndirect) Gets the dependent ranges of all the cells of the range.Gets a DisplayFormat object that represents the display settings for the specified range.Returns a new instance ofIRangewhich represents the same range ofcells, but expanded to include all rows.Returns anIRangerepresenting the area of the current range which isiteratively grown as needed until it includes no partial merged cells.Returns a new instance ofIRangewhich represents the same range ofcells, but expanded to include all columns.getFont()Returns an instance ofIFontwhich may be used to get and set fontproperties of the cells represented by this IRange.Returns a FormatConditions collection that represents all the conditional formats for the specified range.Gets the formula of the cells represented by this range in A1-style notation.Gets the formula of the cells represented by this range in A1-style array notation.Gets the localized formula of the cells represented by this range in A1-style array notation.Gets the formula of the cells represented by this range in R1C1-style array notation.Gets the localized formula of the cells represented by this range in R1C1-style array notation.Gets the array formula of a range.Gets the array formula of a range using ReferenceStyle.R1C1.booleanGets or Sets whether the formula will be hidden when the worksheet is protectedGets the localized formula of the cells represented by this range in A1-style notation.Gets the formula of the cells represented by this range in R1C1-style notation.Gets the localized formula of the cells represented by this range in R1C1-style notation.booleanDetermines if the specified cell is part of an array formula.booleanReturns true if the cell or range contains any formulas; otherwise, false is returned.booleanReturns true if any of the cells represented by this range have data validation associated with them.doubleGets the height, in points, of the range.doubleGets the height, in pixels, of the range.booleanGets the property which specifies whether rows or columns should be hidden.Gets theHorizontalAlignmentof a cell or range.Returns an instance ofIValidationwhich may be used to get and setHyperLinks properties.Gets the error type of the range to be ignored.intGets the indent level of the specified cell(s).Returns theIInteriorwhich represents the interior (background)color and pattern of the specified cell(s).Gets the setting for watermark.intReturns the zero based column number of the last column of the first range.intReturns the zero based row number of the last row of the first range.booleanGets the property which specifies whether cells should be locked.Returns anIRangerepresenting the merged range containing thespecified cell.booleanGets the property which specifies whether cells are merged.Gets the number format of the cells in the range.intGets the text orientation of a cell or range, which may be from -90 to 90 degrees, or 255(vertical text).intGets the current outline level of the specified row or column.Gets the precedent ranges of the left top cell of the range.getPrecedents(boolean includeInDirect) Gets the precedent ranges of all the cells of the range.Gets or Sets the reading order for the specified object.Gets the rich text object associate with the top-left cell of this range.intgetRow()Returns the zero based row number of the first row.intReturns the row count of the first range.doubleGets the height of the individual rows represented by this range in points.doubleGets the height of the individual rows represented by this range in pixels.getRows()Returns theIRangeobject that represents the rows in the specifiedrange.booleanGets whether to show the detail (True if the outline is expanded for the specified range, so that the detail of the column or row is visible).booleanGets the property which specifies whether cells will be drawn in a smaller font if needed to display the contents of the cell.Returns an instance ofISparklineGroupswhich may be used to get andset SparklineGroups properties of the cellsgetStyle()Gets the named styleIStyleassociated with the cells represented bythis IRange.booleanDetermines if the range is an outlining summary row or column.getTag()Gets the tag value of the specified range in the sheet.getText()Gets the value of the cell represented by this IRange as a formatted string.Returns anIRangerepresenting the used range in the current range.getUsedRange(EnumSet<UsedRangeType> type) Returns anIRangerepresenting the used range in the current range.booleanGets whether the row height of theIRangeobject equals the standardheight of the sheet.booleanGets whether the column width of theIRangeobject equals thestandard width of the sheet.Returns an instance ofIValidationwhich may be used to get and setvalidation properties of the cells represented by this IRange.booleanReturns true if the validation options of all cells represented by thisIRangeare the same; otherwise, false is returned.getValue()Gets the value of the specified range as a string, double, boolean,Date, Object[][] or null;Gets theVerticalAlignmentof a cell or range.Gets the watermark for range.doublegetWidth()Gets the width, in points, of the range.doubleGets the width, in pixels, of the range.Returns the parentIWorksheetof this range.booleanGet the flag which indicates whether word wrap is enabled in a cell.booleanAttempts to achieve the specified goal, from the calculated result of the formula in the cell represented by this IRange, by modifying the specified changingCell.voidgroup()Increments the OutlineLevel of the specified rows or columns.importData(Object items) Imports data from a data source (up to 2D) to the range.importData(Object items, DataImportOptions options) Imports data from a data source (up to 2D) to the range.voidinsert()Inserts a cell or a range of cells into the worksheet and shifts other cells away to make space.voidinsert(InsertShiftDirection shiftDirection) Inserts a cell or a range of cells into the worksheet and shifts other cells away to make space.Returns an IRange object that represents the intersection of two ranges.Returns an IRange object that represents the intersection of several ranges.booleanIndicates whether the cell string value is a rich text.voidmerge()Merges the cells in the represented range into a single merged cell.voidmerge(boolean isAcross) Merges the cells in the represented range into a single merged cell.offset(int rowOffset, int columnOffset) Returns an IRange object that represents the offset of this range.voidRemoves subtotals from a list.intSearch in formulas and replace.intreplace(Object what, Object replacement, ReplaceOptions options) Search in formulas and replace.voidselect()Selects the object.voidsetAddIndent(boolean value) Sets the property which controls indentation of text when horizontal or vertical alignment is set to distributed.voidsetBackgroundImage(byte[] backgroundImage) Sets the cell background image.voidsetBackgroundImageLayout(BackgroundImageLayout backgroundImageLayout) Sets the cell background image layout.voidsetBindingPath(String value) Sets the binding path of the current cell or column.voidsetCellPadding(ICellPadding cellPadding) Sets the cell padding for range.voidsetCellType(BaseCellType cellType) Sets the cell type for specified range in the sheet.voidsetColumnWidth(double value) Sets the width of the individual columns represented in this range in characters.voidsetColumnWidthInPixel(double value) Sets the width of the individual columns represented in this range in pixels.voidsetDecoration(ICellDecoration value) Sets the cell decoration for range.voidsetDefaultValue(Object value) Sets the default value of the cell, it can be the value data or the formula string.voidsetFormula(String value) Sets the formula of the cells represented by this range in A1-style notation.voidsetFormula2(String value) Sets the formula of the cells represented by this range in A1-style array notation.voidsetFormula2Local(String value) Sets the localized formula of the cells represented by this range in A1-style array notation.voidsetFormula2R1C1(String value) Sets the formula of the cells represented by this range in R1C1-style array notation.voidsetFormula2R1C1Local(String value) Sets the localized formula of the cells represented by this range in R1C1-style array notation.voidsetFormulaArray(String value) Sets the array formula of a range.voidsetFormulaArrayR1C1(String value) Sets the array formula of a range using ReferenceStyle.R1C1.voidsetFormulaHidden(boolean value) Sets whether the formula will be hidden when the worksheet is protectedvoidsetFormulaLocal(String value) Sets the localized formula of the cells represented by this range in A1-style notation.voidsetFormulaR1C1(String value) Sets the formula of the cells represented by this range in R1C1-style notation.voidsetFormulaR1C1Local(String value) Sets the localized formula of the cells represented by this range in R1C1-style notation.voidsetHidden(boolean value) Sets the property which specifies whether rows or columns should be hidden.voidSets theHorizontalAlignmentof a cell or range.voidsetIgnoredError(EnumSet<IgnoredErrorType> value) Sets the error type of the range to be ignored.voidsetIndentLevel(int value) Sets the indent level of the specified cell(s).voidsetLocked(boolean value) Sets the property which specifies whether cells should be locked.voidsetMergeCells(boolean value) Sets the property which specifies whether cells are merged.voidsetNumberFormat(String value) Sets the number format of the cells in the range.voidsetOrientation(int value) Sets the text orientation of a cell or range, which may be from -90 to 90 degrees, or 255(vertical text).voidsetOutlineLevel(int value) Sets the current outline level of the specified row or column.voidsetReadingOrder(ReadingOrder value) Sets the reading order for the specified object.voidsetRowHeight(double value) Sets the height of the individual rows represented by this range in points.voidsetRowHeightInPixel(double value) Sets the height of the individual rows represented by this range in pixels.voidsetShowDetail(boolean value) Sets whether to show the detail (True if the outline is expanded for the specified range, so that the detail of the column or row is visible).voidsetShrinkToFit(boolean value) Sets the property which specifies whether cells will be drawn in a smaller font if needed to display the contents of the cell.voidSets the named styleIStyleassociated with the cells represented bythis IRange.voidSets the tag value of the specified range in the sheet.voidsetUseStandardHeight(boolean value) Sets whether the row height of theIRangeobject equals the standardheight of the sheet.voidsetUseStandardWidth(boolean value) Sets whether the column width of theIRangeobject equals thestandard width of the sheet.voidvoidSets theVerticalAlignmentof a cell or range.voidsetWatermark(String watermark) Sets the watermark for range.voidsetWrapText(boolean value) Sets the flag which indicates whether word wrap is enabled in a cell.voidsort(IRange key, SortOrder order, SortOrientation orientation) Sorts the cells represented by this range according to the specified options.voidsort(IRange key, SortOrder order, SortOrientation orientation, boolean caseSensitive) Sorts the cells represented by this range according to the specified options.voidsort(SortOrientation orientation, boolean caseSensitive, IValueSortField... keys) Sorts the cells represented by this range according to the specified options.specialCells(SpecialCellType type) Gets a IRange object that represents all the cells that match the specified type and value.specialCells(SpecialCellType type, SpecialCellsValue value) Gets a IRange object that represents all the cells that match the specified type and value.voidsubtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList) Creates subtotals for the range.voidsubtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace) Creates subtotals for the range.voidsubtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace, boolean pageBreaks) Creates subtotals for the range.voidsubtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace, boolean pageBreaks, SummaryRow summaryRowLocation) Creates subtotals for the range.voidsubtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, SummaryRow summaryRowLocation) Creates subtotals for the range.voidtoImage(OutputStream stream, ImageType imageType) Saves the range to the specified image file.voidtoImage(OutputStream stream, ImageType imageType, ImageSaveOptions options) Saves the range to the specified image file using options.voidSaves the range to the specified image file.voidtoImage(String imageFile, ImageSaveOptions options) Saves the range to the specified image file using options.toJson()Generates a json string from the range.voidungroup()Decrements the OutlineLevel of the specified rows or columns.Returns an IRange object that represents the union of two ranges.Returns an IRange object that represents the union of several ranges.voidunmerge()Converts merged cells in the represented range to normal cells.
-
Method Details
-
getRows
IRange getRows()Returns theIRangeobject that represents the rows in the specifiedrange. -
getColumns
IRange getColumns()Returns theIRangeobject that represents the columns in thespecified range. -
getCells
IRange getCells()Returns theIRangeobject that represents the cells in the specifiedrange. -
getRow
int getRow()Returns the zero based row number of the first row. -
getLastRow
int getLastRow()Returns the zero based row number of the last row of the first range. -
getRowCount
int getRowCount()Returns the row count of the first range. -
getColumn
int getColumn()Returns the zero based column number of the first column of this IRange. -
getLastColumn
int getLastColumn()Returns the zero based column number of the last column of the first range. -
getColumnCount
int getColumnCount()Returns the column count of the first range. -
getCount
int getCount()Returns the number of objects in the collection. -
getFont
IFont getFont()Returns an instance ofIFontwhich may be used to get and set fontproperties of the cells represented by this IRange. -
getBorders
IBorders getBorders()Returns an instance ofIBorderswhich represents the cell borders ofthe cell or range represented by this IRange. -
getInterior
IInterior getInterior()Returns theIInteriorwhich represents the interior (background)color and pattern of the specified cell(s). -
getNumberFormat
String getNumberFormat()Gets the number format of the cells in the range. -
setNumberFormat
Sets the number format of the cells in the range. -
getAddIndent
boolean getAddIndent()Gets the property which controls indentation of text when horizontal or vertical alignment is set to distributed. -
setAddIndent
void setAddIndent(boolean value) Sets the property which controls indentation of text when horizontal or vertical alignment is set to distributed. -
getIndentLevel
int getIndentLevel()Gets the indent level of the specified cell(s). -
setIndentLevel
void setIndentLevel(int value) Sets the indent level of the specified cell(s). -
getHidden
boolean getHidden()Gets the property which specifies whether rows or columns should be hidden. -
setHidden
void setHidden(boolean value) Sets the property which specifies whether rows or columns should be hidden. -
getLocked
boolean getLocked()Gets the property which specifies whether cells should be locked. -
setLocked
void setLocked(boolean value) Sets the property which specifies whether cells should be locked. -
getOrientation
int getOrientation()Gets the text orientation of a cell or range, which may be from -90 to 90 degrees, or 255(vertical text). -
setOrientation
void setOrientation(int value) Sets the text orientation of a cell or range, which may be from -90 to 90 degrees, or 255(vertical text). -
getShrinkToFit
boolean getShrinkToFit()Gets the property which specifies whether cells will be drawn in a smaller font if needed to display the contents of the cell. -
setShrinkToFit
void setShrinkToFit(boolean value) Sets the property which specifies whether cells will be drawn in a smaller font if needed to display the contents of the cell. -
getWrapText
boolean getWrapText()Get the flag which indicates whether word wrap is enabled in a cell. -
setWrapText
void setWrapText(boolean value) Sets the flag which indicates whether word wrap is enabled in a cell. -
getHorizontalAlignment
HorizontalAlignment getHorizontalAlignment()Gets theHorizontalAlignmentof a cell or range. -
setHorizontalAlignment
Sets theHorizontalAlignmentof a cell or range. -
getVerticalAlignment
VerticalAlignment getVerticalAlignment()Gets theVerticalAlignmentof a cell or range. -
setVerticalAlignment
Sets theVerticalAlignmentof a cell or range. -
getDisplayFormat
IDisplayFormat getDisplayFormat()Gets a DisplayFormat object that represents the display settings for the specified range. -
getFormulaHidden
boolean getFormulaHidden()Gets or Sets whether the formula will be hidden when the worksheet is protected -
setFormulaHidden
void setFormulaHidden(boolean value) Sets whether the formula will be hidden when the worksheet is protected -
getReadingOrder
ReadingOrder getReadingOrder()Gets or Sets the reading order for the specified object. -
setReadingOrder
Sets the reading order for the specified object. -
getStyle
IStyle getStyle()Gets the named styleIStyleassociated with the cells represented bythis IRange. -
setStyle
Sets the named styleIStyleassociated with the cells represented bythis IRange. -
getValidation
IValidation getValidation()Returns an instance ofIValidationwhich may be used to get and setvalidation properties of the cells represented by this IRange. -
getHyperlinks
IHyperlinks getHyperlinks()Returns an instance ofIValidationwhich may be used to get and setHyperLinks properties. -
getComment
IComment getComment()Returns an instance ofICommentwhich may be used to get and setComment properties of the cells. -
getSparklineGroups
ISparklineGroups getSparklineGroups()Returns an instance ofISparklineGroupswhich may be used to get andset SparklineGroups properties of the cells -
getWorksheet
IWorksheet getWorksheet()Returns the parentIWorksheetof this range. -
getEntireRow
IRange getEntireRow()Returns a new instance ofIRangewhich represents the same range ofcells, but expanded to include all columns. -
getEntireColumn
IRange getEntireColumn()Returns a new instance ofIRangewhich represents the same range ofcells, but expanded to include all rows. -
getEntireMergeArea
IRange getEntireMergeArea()Returns anIRangerepresenting the area of the current range which isiteratively grown as needed until it includes no partial merged cells. -
getMergeArea
IRange getMergeArea()Returns anIRangerepresenting the merged range containing thespecified cell. If the specified cell isn't in a merged range, this property returns the specified cell. -
getFormula
String getFormula()Gets the formula of the cells represented by this range in A1-style notation. -
setFormula
Sets the formula of the cells represented by this range in A1-style notation. -
getFormulaLocal
String getFormulaLocal()Gets the localized formula of the cells represented by this range in A1-style notation. -
setFormulaLocal
Sets the localized formula of the cells represented by this range in A1-style notation. -
getFormulaR1C1
String getFormulaR1C1()Gets the formula of the cells represented by this range in R1C1-style notation. -
setFormulaR1C1
Sets the formula of the cells represented by this range in R1C1-style notation. -
getFormulaR1C1Local
String getFormulaR1C1Local()Gets the localized formula of the cells represented by this range in R1C1-style notation. -
setFormulaR1C1Local
Sets the localized formula of the cells represented by this range in R1C1-style notation. -
getFormula2
String getFormula2()Gets the formula of the cells represented by this range in A1-style array notation. -
setFormula2
Sets the formula of the cells represented by this range in A1-style array notation. -
getFormula2Local
String getFormula2Local()Gets the localized formula of the cells represented by this range in A1-style array notation. -
setFormula2Local
Sets the localized formula of the cells represented by this range in A1-style array notation. -
getFormula2R1C1
String getFormula2R1C1()Gets the formula of the cells represented by this range in R1C1-style array notation. -
setFormula2R1C1
Sets the formula of the cells represented by this range in R1C1-style array notation. -
getFormula2R1C1Local
String getFormula2R1C1Local()Gets the localized formula of the cells represented by this range in R1C1-style array notation. -
setFormula2R1C1Local
Sets the localized formula of the cells represented by this range in R1C1-style array notation. -
getFormulaArray
String getFormulaArray()Gets the array formula of a range. -
setFormulaArray
Sets the array formula of a range. -
getFormulaArrayR1C1
String getFormulaArrayR1C1()Gets the array formula of a range using ReferenceStyle.R1C1. -
setFormulaArrayR1C1
Sets the array formula of a range using ReferenceStyle.R1C1. -
getCurrentArray
IRange getCurrentArray()Gets whether the specified cell is part of an array, returns anIRangeobject that represents the entire array. -
getHasFormula
boolean getHasFormula()Returns true if the cell or range contains any formulas; otherwise, false is returned. -
getHasArray
boolean getHasArray()Determines if the specified cell is part of an array formula. -
getValue
Object getValue()Gets the value of the specified range as a string, double, boolean,Date, Object[][] or null; -
setValue
-
setIgnoredError
Sets the error type of the range to be ignored.- Parameters:
value- The EnumSet ofIgnoredErrorType.
-
getIgnoredError
EnumSet<IgnoredErrorType> getIgnoredError()Gets the error type of the range to be ignored.- Returns:
- The EnumSet of
IgnoredErrorType.
-
getTag
Object getTag()Gets the tag value of the specified range in the sheet. -
setTag
Sets the tag value of the specified range in the sheet. -
getCellType
BaseCellType getCellType()Gets the cell type for specified range in the sheet. -
setCellType
Sets the cell type for specified range in the sheet. -
getBindingPath
String getBindingPath()Gets the binding path of the current cell or column. If range is normal range, returns the binding path of the top-left cell of range. If range is EntireColumn, returns the binding path of the left column binding path of range. If range is EntireRow, returns null. -
setBindingPath
Sets the binding path of the current cell or column. If range is normal range, sets the binding path of the top-left cell of range. If range is EntireColumn, sets the binding path of the left column binding path of range. If range is EntireRow, do nothing. -
getText
String getText()Gets the value of the cell represented by this IRange as a formatted string. -
getAreas
IAreas getAreas()Returns an instance ofIAreaswhich represents an array of rangeswhere each range returned by areas represents one cell or range. -
getUsedRange
IRange getUsedRange()Returns anIRangerepresenting the used range in the current range. -
getUsedRange
Returns anIRangerepresenting the used range in the current range.- Parameters:
type- The feature type.
-
get
Returns a new instance ofIRangewhich is offset from this range.- Parameters:
rowOffset- The row offset.columnOffset- The column offset.- Returns:
- IRange.
-
get
Returns a new instance ofIRangeby index which represents a cell.- Parameters:
index- The index of the range.
-
getMergeCells
boolean getMergeCells()Gets the property which specifies whether cells are merged. -
setMergeCells
void setMergeCells(boolean value) Sets the property which specifies whether cells are merged. -
merge
void merge()Merges the cells in the represented range into a single merged cell. -
merge
void merge(boolean isAcross) Merges the cells in the represented range into a single merged cell.- Parameters:
isAcross- Optional Object. True to merge cells in each row of thespecified range as separate merged cells. The default value is False.
-
unmerge
void unmerge()Converts merged cells in the represented range to normal cells. -
insert
void insert()Inserts a cell or a range of cells into the worksheet and shifts other cells away to make space. -
insert
Inserts a cell or a range of cells into the worksheet and shifts other cells away to make space.- Parameters:
shiftDirection- Specifies which way to shift the cells.
-
delete
void delete()Deletes a cell or a range of cells from the worksheet and shifts other cells to replace deleted cells. -
delete
Deletes a cell or a range of cells from the worksheet and shifts other cells to replace deleted cells.- Parameters:
shiftDirection- Specifies which way to shift the cells.
-
clear
void clear()Clears formulas, values, and all formatting from the current range. -
clearContents
void clearContents()Clears formulas and values from the current range. -
clearFormats
void clearFormats()Clears all formatting from the current range. -
clearHyperlinks
void clearHyperlinks()Clears all hyperLinks from the current range. -
clearComments
void clearComments()Clears the comments from the current range -
clearCommentsThreaded
void clearCommentsThreaded()Clears the threaded comments from the current range. -
addComment
Adds comments to the current range.- Parameters:
text- The text you want to add.
-
sort
Sorts the cells represented by this range according to the specified options.- Parameters:
orientation- The orientation.caseSensitive- if set to true, case sensitive.keys- TheIValueSortFieldarray.
-
sort
Sorts the cells represented by this range according to the specified options.- Parameters:
key- The key of the sort column.order- The sort order, ascending or dscendingorientation- The orientation.caseSensitive- if set to true, case sensitive.
-
sort
Sorts the cells represented by this range according to the specified options.- Parameters:
key- The key of the sort column.order- The sort order, ascending or dscendingorientation- The orientation.
-
autoFilter
void autoFilter(int field, Object criteria1, AutoFilterOperator op, Object criteria2, boolean visibleDropDown) Filters a list using the AutoFilter.- Parameters:
field- Optional Object. The integer offset of the field onwhich you want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperatorcriteria2- Optional Object. The second criteria (a string). Usedwith Criteria1 and Operator to construct compound criteria.visibleDropDown- Optional Object. True to display the AutoFilterdrop-down arrow for the filtered field; False to hide the AutoFilter drop-down arrow for the filtered field. True by default.
-
autoFilter
void autoFilter(int field) Filters a list using the AutoFilter.- Parameters:
field- Optional Object. The integer offset of the field on which youwant to base the filter (from the left of the list; the leftmost field is field zero).
-
autoFilter
void autoFilter()Filters a list using the AutoFilter.
Add a filter with no condition if there's no filter in the sheet.
Or show all the data in the first column of the filter. -
autoFilter
Filters a list using the AutoFilter.- Parameters:
field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").
-
autoFilter
Filters a list using the AutoFilter.- Parameters:
field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperator
-
autoFilter
Filters a list using the AutoFilter.- Parameters:
field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperatorcriteria2- Optional Object. The second criteria (a string). Used withCriteria1 and Operator to construct compound criteria.
-
autoFilter
void autoFilter(boolean isFirstRowData, int field, Object criteria1, AutoFilterOperator op, Object criteria2, boolean visibleDropDown) Filters a list using the AutoFilter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.field- Optional Object. The integer offset of the field onwhich you want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperatorcriteria2- Optional Object. The second criteria (a string). Usedwith Criteria1 and Operator to construct compound criteria.visibleDropDown- Optional Object. True to display the AutoFilterdrop-down arrow for the filtered field; False to hide the AutoFilter drop-down arrow for the filtered field. True by default.
-
autoFilter
void autoFilter(boolean isFirstRowData) Filters a list using the AutoFilter.
Add a filter with no condition if there's no filter in the sheet.
Or show all the data in the first column of the filter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.
-
autoFilter
void autoFilter(boolean isFirstRowData, int field) Filters a list using the AutoFilter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.field- Optional Object. The integer offset of the field on which youwant to base the filter (from the left of the list; the leftmost field is field zero).
-
autoFilter
Filters a list using the AutoFilter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").
-
autoFilter
Filters a list using the AutoFilter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperator
-
autoFilter
void autoFilter(boolean isFirstRowData, int field, Object criteria1, AutoFilterOperator op, Object criteria2) Filters a list using the AutoFilter.- Parameters:
isFirstRowData- Indicates whether the first row of the selection area participates in filtering.When set to true, the behavior is consistent with SpreadJS; when false, it is consistent with Microsoft Excel.field- Optional Object. The integer offset of the field on whichyou want to base the filter (from the left of the list; the leftmost field is field zero).criteria1- Optional Object. The criteria (a string; for example,"101"). Use "=" to find blank fields, or use " <>" to find nonblank fields. If this argument is omitted, the criteria is All. If Operator is xlTop10Items, Criteria1 specifies the number of items (for example, "10").op- Optional AutoFilterOperatorcriteria2- Optional Object. The second criteria (a string). Used withCriteria1 and Operator to construct compound criteria.
-
getWidth
double getWidth()Gets the width, in points, of the range. -
getWidthInPixel
double getWidthInPixel()Gets the width, in pixels, of the range. -
getColumnWidth
double getColumnWidth()Gets the width of the individual columns represented in this range in characters. -
setColumnWidth
void setColumnWidth(double value) Sets the width of the individual columns represented in this range in characters. -
getColumnWidthInPixel
double getColumnWidthInPixel()Gets the width of the individual columns represented in this range in pixels. -
setColumnWidthInPixel
void setColumnWidthInPixel(double value) Sets the width of the individual columns represented in this range in pixels. -
getHeight
double getHeight()Gets the height, in points, of the range. -
getHeightInPixel
double getHeightInPixel()Gets the height, in pixels, of the range. -
getRowHeight
double getRowHeight()Gets the height of the individual rows represented by this range in points. -
setRowHeight
void setRowHeight(double value) Sets the height of the individual rows represented by this range in points. -
getRowHeightInPixel
double getRowHeightInPixel()Gets the height of the individual rows represented by this range in pixels. -
setRowHeightInPixel
void setRowHeightInPixel(double value) Sets the height of the individual rows represented by this range in pixels. -
getFormatConditions
IFormatConditions getFormatConditions()Returns a FormatConditions collection that represents all the conditional formats for the specified range. -
clearOutline
void clearOutline()Clears the outline for the specified range. -
group
void group()Increments the OutlineLevel of the specified rows or columns. -
ungroup
void ungroup()Decrements the OutlineLevel of the specified rows or columns. -
getOutlineLevel
int getOutlineLevel()Gets the current outline level of the specified row or column. -
setOutlineLevel
void setOutlineLevel(int value) Sets the current outline level of the specified row or column. -
getShowDetail
boolean getShowDetail()Gets whether to show the detail (True if the outline is expanded for the specified range, so that the detail of the column or row is visible). The specified range must be a single summary column or row in an outline.The following statements are true: 1.The range must be in a single summary row or column. 2.This property returns False if any of the children of the row or column are hidden. 3.Setting this property to True is equivalent to unhiding all the children of the summary row or column. 4.Setting this property to False is equivalent to hiding all the children of the summary row or column.
-
setShowDetail
void setShowDetail(boolean value) Sets whether to show the detail (True if the outline is expanded for the specified range, so that the detail of the column or row is visible). The specified range must be a single summary column or row in an outline.The following statements are true: 1.The range must be in a single summary row or column. 2.This property returns False if any of the children of the row or column are hidden. 3.Setting this property to True is equivalent to unhiding all the children of the summary row or column. 4.Setting this property to False is equivalent to hiding all the children of the summary row or column.
-
getSummary
boolean getSummary()Determines if the range is an outlining summary row or column. -
activate
void activate()Activates a single cell, which must be inside the current selection. -
select
void select()Selects the object. -
copy
Copies the range to the specified range -
copy
Deprecated.This method is no longer acceptable to compute time between versions.Use
copy(IRange,PasteOption)instead.Copies the range to the specified range.- Parameters:
destination- Specifies the new range to which the specified range willbe pasted. It can be the range of the same or another workbook.pasteType- Specifies the part of the range to be pasted.
-
copy
Copies the range to the specified range.- Parameters:
destination- Specifies the new range to which the specified range willbe pasted. It can be the range of the same or another workbook.pasteOption- Specifies the part of the range to be pasted andwhether to include hidden range.
-
cut
Cuts the range to the specified range.- Parameters:
destination- Specifies the new range to which the specified range willbe pasted. It can be the range of the same or another workbook.
-
getHasValidation
boolean getHasValidation()Returns true if any of the cells represented by this range have data validation associated with them. -
getValidationIsSame
boolean getValidationIsSame()Returns true if the validation options of all cells represented by thisIRangeare the same; otherwise, false is returned. -
getUseStandardHeight
boolean getUseStandardHeight()Gets whether the row height of theIRangeobject equals the standardheight of the sheet. -
setUseStandardHeight
void setUseStandardHeight(boolean value) Sets whether the row height of theIRangeobject equals the standardheight of the sheet. -
getUseStandardWidth
boolean getUseStandardWidth()Gets whether the column width of theIRangeobject equals thestandard width of the sheet. -
setUseStandardWidth
void setUseStandardWidth(boolean value) Sets whether the column width of theIRangeobject equals thestandard width of the sheet. -
calculate
void calculate()Calculates formulas of the range as needed. -
dirty
void dirty()Designates all the formulas of the range to be recalculated when the next calculation occurs. -
isRichText
boolean isRichText()Indicates whether the cell string value is a rich text. -
getRichText
IRichText getRichText()Gets the rich text object associate with the top-left cell of this range. -
characters
Returns a ITextRun object that represents a range of characters within the cell text. -
find
Finds specific information in a range.- Parameters:
what- The data to search for. Can be a String, double, Date,Calendar, boolean or int.after- The cell after which you want the search to begin. Thiscorresponds to the position of the active cell when a search is done from the user interface. Notice that After must be a single cell in the range. Remember that the search begins after this cell; the specified cell isn't searched until the method wraps back around to this cell. If you do not specify this argument, the search starts at the cell in the upper-left corner of the range when FindOptions.SearchDirection is SearchDirection.Next, or at the cell in the bottom-right corner of the range when FindOptions.SearchDirection is SearchDirection.Previous.options- The find options- Returns:
- A IRange object that represents the first cell where that informationis found.
-
find
Finds specific information in a range.- Parameters:
what- The data to search for. Can be a String, double, Date,LocalDateTime, Calendar, boolean or int.after- The cell after which you want the search to begin. Thiscorresponds to the position of the active cell when a search is done from the user interface. Notice that After must be a single cell in the range. Remember that the search begins after this cell; the specified cell isn't searched until the method wraps back around to this cell. If you do not specify this argument, the search starts at the cell in the upper-left corner of the range when FindOptions.SearchDirection is SearchDirection.Next, or at the cell in the bottom-right corner of the range when FindOptions.SearchDirection is SearchDirection.Previous.- Returns:
- A IRange object that represents the first cell where that informationis found.
-
find
Finds specific information in a range, starts from the upper-left corner.- Parameters:
what- The data to search for. Can be a String, double, Date,LocalDateTime, Calendar, boolean or int.- Returns:
- A IRange object that represents the first cell where that informationis found.
-
find
Finds specific information in a range, starts from the upper-left corner.- Parameters:
what- The data to search for. Can be a String, double, Date,LocalDateTime, Calendar, boolean or int.options- The find options- Returns:
- A IRange object that represents the first cell where that informationis found.
-
replace
Search in formulas and replace. Using this method doesn't change either the selection or the active cell.- Parameters:
what- The string you want to search for.replacement- The replacement string.- Returns:
- Number of cells that was replaced.
-
replace
Search in formulas and replace. Using this method doesn't change either the selection or the active cell.- Parameters:
what- The string you want to search for.replacement- The replacement string.options- The replace options.- Returns:
- Number of cells that was replaced.
-
autoFit
void autoFit()Changes the width of the columns in the range or the height of the rows in the range to achieve the best fit. -
autoFit
void autoFit(boolean considerMergedCell) Changes the width of the columns in the range or the height of the rows in the range to achieve the best fit.- Parameters:
considerMergedCell- Indicates whether to consider merged cells in a single row.
-
subtotal
Creates subtotals for the range.- Parameters:
groupBy- The field to group by, as a one-based integer offset.subtotalFunction- The subtotal function.totalList- An array of 1-based field offsets, indicating the fields to which the subtotals are added.
-
subtotal
void subtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace) Creates subtotals for the range.- Parameters:
groupBy- The field to group by, as a one-based integer offset.subtotalFunction- The subtotal function.totalList- An array of 1-based field offsets, indicating the fields to which the subtotals are added.replace- True to replace existing subtotals. The default value is True.
-
subtotal
void subtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace, boolean pageBreaks) Creates subtotals for the range.- Parameters:
groupBy- The field to group by, as a one-based integer offset.subtotalFunction- The subtotal function.totalList- An array of 1-based field offsets, indicating the fields to which the subtotals are added.replace- True to replace existing subtotals. The default value is True.pageBreaks- True to add page breaks after each group. The default value is False.
-
subtotal
void subtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, SummaryRow summaryRowLocation) Creates subtotals for the range.- Parameters:
groupBy- The field to group by, as a one-based integer offset.subtotalFunction- The subtotal function.totalList- An array of 1-based field offsets, indicating the fields to which the subtotals are added.summaryRowLocation- Places the summary data relative to the subtotal. The default value is Below.
-
subtotal
void subtotal(int groupBy, ConsolidationFunction subtotalFunction, int[] totalList, boolean replace, boolean pageBreaks, SummaryRow summaryRowLocation) Creates subtotals for the range.- Parameters:
groupBy- The field to group by, as a one-based integer offset.subtotalFunction- The subtotal function.totalList- An array of 1-based field offsets, indicating the fields to which the subtotals are added.replace- True to replace existing subtotals. The default value is True.pageBreaks- True to add page breaks after each group. The default value is False.summaryRowLocation- Places the summary data relative to the subtotal. The default value is Below.
-
removeSubtotal
void removeSubtotal()Removes subtotals from a list. -
getPrecedents
Gets the precedent ranges of the left top cell of the range. -
getPrecedents
Gets the precedent ranges of all the cells of the range.- Parameters:
includeInDirect- Indicates whether to include indirect precedents.
-
getDependents
Gets the dependent ranges of the left top cell of the range. -
getDependents
Gets the dependent ranges of all the cells of the range.- Parameters:
includeIndirect- Include the indirect dependent cells.
-
toImage
Saves the range to the specified image file.- Parameters:
imageFile- The output image file.
-
toImage
Saves the range to the specified image file using options.- Parameters:
imageFile- The output image file.options- The options for output image.
-
toImage
Saves the range to the specified image file.- Parameters:
stream- The output image stream.imageType- Specifies the type of image to create.
-
toImage
Saves the range to the specified image file using options.- Parameters:
stream- The output image stream.imageType- Specifies the type of image to create.options- The options for output image.
-
getAddress
String getAddress()Returns a String value that represents the range reference. -
getAddress
Returns a String value that represents the range reference.- Parameters:
columnAbsolute- True to return the column part of the reference as an absolute reference.The default value is true.rowAbsolute- True to return the row part of the reference as an absolute reference.The default value is true.
-
getAddress
Returns a String value that represents the range reference.- Parameters:
columnAbsolute- True to return the column part of the reference as an absolute reference.The default value is true.rowAbsolute- True to return the row part of the reference as an absolute reference.The default value is true.referenceStyle- The reference style. The default value is A1.
-
getAddress
String getAddress(boolean rowAbsolute, boolean columnAbsolute, ReferenceStyle referenceStyle, IRange relativeTo) Returns a String value that represents the range reference.- Parameters:
columnAbsolute- True to return the column part of the reference as an absolute reference.The default value is true.rowAbsolute- True to return the row part of the reference as an absolute reference.The default value is true.referenceStyle- The reference style. The default value is A1.relativeTo- If RowAbsolute and ColumnAbsolute are false,and ReferenceStyle is R1C1, defines a starting point for the relative reference. The default reference is $A1ドル.
-
specialCells
Gets a IRange object that represents all the cells that match the specified type and value. -
specialCells
Gets a IRange object that represents all the cells that match the specified type and value. -
getCellPadding
ICellPadding getCellPadding()Gets the cell padding for range.- Returns:
- An
ICellPaddingobjectSpreadJS only.
-
setCellPadding
Sets the cell padding for range.- Parameters:
cellPadding- SpreadJS only.
-
getWatermark
String getWatermark()Gets the watermark for range. SpreadJS only.- Returns:
- the watermark string
-
setWatermark
Sets the watermark for range. SpreadJS only.- Parameters:
watermark- The watermark string
-
getDecoration
ICellDecoration getDecoration()Gets the cell decoration for range. SpreadJS only.- Returns:
- The cell decoration.
-
setDecoration
Sets the cell decoration for range. SpreadJS only.- Parameters:
value- The cell decoration.
-
getLabelOptions
ILabelOptions getLabelOptions()Gets the setting for watermark.- Returns:
- An
ILabelOptionsobjectSpreadJS only.
-
fromJson
Generates the range data from the json string.- Parameters:
json- the json string that contains range info.
-
toJson
String toJson()Generates a json string from the range.- Returns:
- the json string that contains range info.
-
addCommentThreaded
Adds a threaded comment to the range.- Parameters:
text- The string is content of the threaded comment.
-
addCommentThreaded
Adds a threaded comment to the range.- Parameters:
text- The string is content of the threaded comment.author- Author name of the threaded comment.- Returns:
- The newly added threaded comment.
-
getCommentThreaded
ICommentThreaded getCommentThreaded()- Returns:
- Gets the threaded comment of specific cell
-
generateGetPivotDataFunction
Generate the corresponding function "GETPIVOTDATA" for the cells in the pivot table.- Parameters:
destination- Indicates for which area the "GETPIVOTDATA" function is generated.- Returns:
- "GETPIVOTDATA" function
-
generateGetPivotDataFunction
String generateGetPivotDataFunction()Generate the corresponding function "GETPIVOTDATA" for the cells in the pivot table.- Returns:
- "GETPIVOTDATA" function
-
intersect
Returns an IRange object that represents the intersection of two ranges.
If range2 is from a different worksheet, an exception is thrown.- Parameters:
range2- The range to intersect with this range.- Returns:
- A new range which consists of the intersection of this range and range2, or null if the ranges do not intersect.
-
intersect
Returns an IRange object that represents the intersection of several ranges.
If one or more ranges from a different worksheet are specified, an exception is thrown.- Parameters:
ranges- The intersecting ranges.- Returns:
- A new range which consists of the intersection of this range and other ranges, or null if the ranges do not intersect.
-
union
Returns an IRange object that represents the union of two ranges.
If range2 is from a different worksheet, an exception is thrown.- Parameters:
range2- The range to union with this range.- Returns:
- A new range which consists of the union of this range and range2.
-
union
Returns an IRange object that represents the union of several ranges.
If one or more ranges from a different worksheet are specified, an exception is thrown.- Parameters:
ranges- Other ranges to union with this range.- Returns:
- A new range which consists of the union of this range and other ranges.
-
offset
Returns an IRange object that represents the offset of this range.- Parameters:
rowOffset- Row offset.columnOffset- Column offset.- Returns:
- A new range which consists of the offset of this range.
-
getDefaultValue
Object getDefaultValue()Gets the default value of the cell, it can be the value data or the formula string. It works when the cell has no data. -
setDefaultValue
Sets the default value of the cell, it can be the value data or the formula string. It works when the cell has no data. -
goalSeek
Attempts to achieve the specified goal, from the calculated result of the formula in the cell represented by this IRange, by modifying the specified changingCell. If you know the result that you want from a formula, but are not sure what input value the formula needs to get that result, use the Goal Seek feature.- Parameters:
goal- Specifies the desired goal value.changingCell- Specifies the cell to change.- Returns:
- True if the specified goal value is successfully found, otherwise False.
-
getBackgroundImage
byte[] getBackgroundImage()Gets the cell background image.- Returns:
- Cell background image byte array.
-
setBackgroundImage
void setBackgroundImage(byte[] backgroundImage) Sets the cell background image. Supported image types include: PNG, JPG, ICO, SVG, GIF. This would be visible only in SpreadJS and Exporting to PDF/HTML/IMG.- Parameters:
backgroundImage- Cell background image byte array.
-
getBackgroundImageLayout
BackgroundImageLayout getBackgroundImageLayout()Gets the cell background image layout, default is Stretch.- Returns:
- Background image layout of cell.
-
setBackgroundImageLayout
Sets the cell background image layout.- Parameters:
backgroundImageLayout- Background image layout of cell.
-
importData
Imports data from a data source (up to 2D) to the range.- Parameters:
items- The items to import. The element type can be:- Primitive value types:
byte,short,int,long,float,double,boolean. - Nullable primitives:
Byte,Short,Integer,Long,Float,Double,Boolean,String,CalcError, Classic date and time types:Date,Calendar, JSR310 date and time types:LocalDate,LocalTime,LocalDateTime,OffsetTime,OffsetDateTime,ZonedDateTime,Instant,YearMonth,Year,MonthDay. (Note:DurationandPeriodare not supported at this time) - Custom objects: objects that have public get methods (properties in Kotlin) to be mapped to cell values.
-
Mapwhere the key isString: It will be treated as a collection of property names and values.
- Flat (non-jagged, 1D in total)
Iterableor array. - Jagged 2D array where the element type of the inner collection is primitive or nullable primitive.
- Primitive value types:
- Throws:
ClassCastException- The data type of column is inconsistent. UseDataImportOptions.setItemTypeProvider(java.util.function.Function<java.lang.Object, java.lang.Class<?>>)to fix it.IllegalArgumentException- An item is of an unsupported type oroptionscontains incorrect information.- API Note:
- If the items are a list or array of primitive types, the orientation is determined by the shape of the range. If the row count of the range is greater than column count, we import the collection vertically. Otherwise, we import the collection horizontally.
-
importData
Imports data from a data source (up to 2D) to the range.- Parameters:
items- The items to import. The element type can be:- Primitive value types:
byte,short,int,long,float,double,boolean. - Nullable primitives:
Byte,Short,Integer,Long,Float,Double,Boolean,String,CalcError, Classic date and time types:Date,Calendar, JSR310 date and time types:LocalDate,LocalTime,LocalDateTime,OffsetTime,OffsetDateTime,ZonedDateTime,Instant,YearMonth,Year,MonthDay. (Note:DurationandPeriodare not supported at this time) - Custom objects: objects that have public get methods (properties in Kotlin) to be mapped to cell values.
-
Mapwhere the key isString: It will be treated as a collection of property names and values.
- Flat (non-jagged, 1D in total)
Iterableor array. - Jagged 2D array where the element type of the inner collection is primitive or nullable primitive.
- Primitive value types:
options- The import options.- Throws:
ClassCastException- The data type of column is inconsistent. UseDataImportOptions.setItemTypeProvider(java.util.function.Function<java.lang.Object, java.lang.Class<?>>)to fix it.IllegalArgumentException- An item is of an unsupported type oroptionscontains incorrect information.- API Note:
- If the items are a list or array of primitive types, the orientation is determined by the shape of the range. If the row count of the range is greater than column count, we import the collection vertically. Otherwise, we import the collection horizontally.
-