xlsrange-ag凯发旗舰厅



com.spire.xls.core.spreadsheet
class xlsrange

java.lang.object
  extended by com.spire.xls.core.spreadsheet.xlsobject
      extended by com.spire.xls.core.spreadsheet.xlsrange
all implemented interfaces:
icombinedrange, ixlsrange, java.lang.iterable
direct known subclasses:
cellrange

public class xlsrange
extends xlsobject
implements icombinedrange, java.lang.iterable

represents the xlsrange.


constructor summary
xlsrange(java.lang.object parent)
           
xlsrange(java.lang.object parent, int column, int row)
           
xlsrange(java.lang.object parent, int firstcol, int firstrow, int lastcol, int lastrow)
           
 
method summary
 ixlsrange activate()
          active single cell in the worksheet
 ixlsrange activate(boolean scroll)
          activates a single cell, scroll to it and activates the corresponding sheet.
 cellrange addcombinedrange(cellrange cr)
          add combined range
 icommentshape addcomment()
          adds a comment to the range.
 icommentshape addcomment(boolean bisparseoptions)
          adds a comment to the range.
 void autofitcolumns()
          changes the width of the columns in the range to achieve the best fit.
 void autofitrows()
          automatically adjust the height and width of the rows
 void borderaround()
          sets around border for current range.
 void borderaround(linestyletype borderline)
          sets around border for current range.
 void borderaround(linestyletype borderline, java.awt.color bordercolor)
          sets around border for current range.
 void borderaround(linestyletype borderline, excelcolors bordercolor)
          sets around border for current range.
 void borderinside()
          sets inside border for current range.
 void borderinside(linestyletype borderline)
          sets inside border for current range.
 void borderinside(linestyletype borderline, java.awt.color bordercolor)
          sets inside border for current range.
 void borderinside(linestyletype borderline, excelcolors bordercolor)
          sets inside border for current range.
 void bordernone()
          sets none border for current range.
 void clear(excelclearoptions option)
          clears the cell based on clear options.
 void clearall()
          clears the entire object.
 void clearconditionalformats()
          clears conditional formats.
 void clearcontents()
          clear the contents of the range.
 void collapsegroup(groupbytype groupby)
          collapses current group.
 void converttonumber()
          convert number that stored as text to number
 ixlsrange deepclone(java.lang.object parent, java.util.hashmap rangenames, xlsworkbook book)
          clones current ixlsrange.
 void dispose()
          this method is called when disposing the object.
 void expandgroup(groupbytype groupby)
          expands current group.
 void freezepanes()
          freezes panes at the current range in the worksheet.
 ixlsrange get(int row, int column)
          gets / sets cell by row and column index.
 ixlsrange get(int row, int column, int lastrow, int lastcolumn)
          get cell range.
 ixlsrange get(java.lang.string name)
          gets cell range.
 ixlsrange get(java.lang.string name, boolean isr1c1notation)
          gets cell range.
 boolean getbooleanvalue()
          returns or sets the bool value of the specified range.
 iborders getborders()
          returns a borders collection that represents the borders of a style or a range of cells (including a range defined as part of a conditional format).
 builtinstyles getbuiltinstyle()
          gets/sets built in style.
 java.util.arraylist<cellrange> getcelllist()
          returns a range object that represents the cells in the specified range.
 int getcellscount()
          gets number of cells.
 java.lang.string getcellstylename()
          gets/sets name of the style for the current range.
 int getcolumn()
          returns the number of the first column in the first area in the specified range.
 int getcolumncount()
          gets number of columns.
 int getcolumngrouplevel()
          column group level.
 ixlsrange[] getcolumns()
          for a range object, it returns an array of range objects that represent the columns in the specified range.
 double getcolumnwidth()
          returns or sets the width of all columns in the specified range.
 icommentshape getcomment()
          returns a comment object that represents the comment associated with the cell in the upper-left corner of the range.
 conditionalformats getconditionalformats()
          collection of conditional formats for the range.
 int getcount()
          returns the number of objects in the collection.
 validation getdatavalidation()
          gets datavalidation of the sheet.
 java.util.date getdatetimevalue()
          gets datetime value of the range.
 java.lang.string getdisplayedtext()
          gets cell displayed text.
 ixlsrange getendcell()
          returns a range object that represents the cell at the end of the region that contains the source range.
 ixlsrange getentirecolumn()
          returns a range object that represents the entire column (or columns) that contains the specified range.
 ixlsrange getentirerow()
          returns a range object that represents the entire row (or rows) that contains the specified range.
 java.lang.string getenvalutedvalue()
          returns the calculated value of a formula.
 java.lang.string geterrorvalue()
          gets or sets error value of this range.
 int getextendedformatindex()
          sets / gets index of extended format.
 java.lang.string getformula()
          returns the object's formula in a1-style notation and in the language of the macro.
 java.lang.string getformulaarray()
          returns or sets the array formula of a range.
 java.lang.string getformulaarrayr1c1()
          returns or sets the formula for the object, using r1c1-style notation in the language of the macro
 boolean getformulaboolvalue()
          gets or sets bool value of the formula.
 java.util.date getformuladatetime()
          gets or sets bool value of the formula.
 java.lang.string getformulaerrorvalue()
          gets or sets error value of the formula.
 double getformulanumbervalue()
          gets the double value of the formula.
 java.lang.string getformular1c1()
          returns or sets the formula for the object, using r1c1-style notation in the language of the macro
 java.lang.string getformulastringvalue()
          gets or sets string value of the range.
 java.lang.object getformulavalue()
          gets formula value.
 horizontalaligntype gethorizontalalignment()
          returns or sets the horizontal alignment for the specified object.
 java.lang.string gethtmlstring()
          gets the html string which contains data and some formattings in this cell.
 ihyperlinks gethyperlinks()
          returns hyperlinks for this range.
 java.util.enumset<ignoreerrortype> getignoreerroroptions()
          represents ignore error options.
 int getindentlevel()
          returns or sets the indent level for the cell or range.
 int getlastcolumn()
          gets or sets last column of the range.
 int getlastrow()
          gets or sets last row of the range.
 ixlsrange getmergearea()
          returns a range object that represents the merged range containing the specified cell.
 java.lang.string getnewrangelocation(java.util.hashmap names, java.lang.string[] sheetname)
          gets new range location.
 java.lang.string getnumberformat()
          returns or sets the format code for the object.
 java.lang.string getnumbertext()
          returns cell text for number format.
 double getnumbervalue()
          gets or sets number value of the range.
 java.lang.object getparent()
          parent object for this object.
 java.lang.string getrangeaddress()
          returns the range reference in the language of the macro.
 java.lang.string getrangeaddresslocal()
          returns the range reference for the specified range in the language of the user.
 java.lang.string getrangeglobaladdress()
          returns the range reference in the language of the macro.
 java.lang.string getrangeglobaladdress2007()
          gets address global in the format required by excel 2007.
 java.lang.string getrangeglobaladdresswithoutsheetname()
          return global address without worksheet name.
 java.lang.string getranger1c1address()
          returns the range reference using r1c1 notation.
 java.lang.string getranger1c1addresslocal()
          returns the range reference using r1c1 notation.
 java.awt.rectangle[] getrectangles()
          gets rectangle information of current range.
 irichtextstring getrichtext()
          returns a richtextstring object that represents the rich text style.
 int getrow()
          returns the number of the first row of the first area in the range.
 int getrowcount()
          gets number of rows.
 int getrowgrouplevel()
          row group level.
 double getrowheight()
          returns the height of all the rows in the range specified, measured in points.
 ixlsrange[] getrows()
          for a range object, it returns an array of range objects that represent the rows in the specified range.
 istyle getstyle()
          returns a style object that represents the style of the specified range.
 java.lang.string gettext()
          gets / sets text of range.
 java.lang.string getvalue()
          returns the value of the specified range.
 java.lang.object getvalue2()
          returns or sets the cell value.
 verticalaligntype getverticalalignment()
          returns or sets the vertical alignment of the specified object.
 iworksheet getworksheet()
          returns a worksheet object that represents the worksheet containing the specified range.
 java.lang.string getworksheetname()
          returns name of the parent worksheet.
 cellrange groupbycolumns(boolean iscollapsed)
          groups columns.
 cellrange groupbyrows(boolean iscollapsed)
          groups row.
 boolean hasboolean()
          indicates whether range contains bool value.
 boolean hascomment()
           
 boolean hasconditionformats()
          indicates whether each cell of the range has some conditional formatting.
 boolean hasdatavalidation()
          indicates whether specified range object has data validation.
 boolean hasdatetime()
          determines if all cells in the range contain datetime.
 boolean haserror()
          indicates whether range contains error value.
 boolean hasexternalformula()
          check if the formula in the range has external links.
 boolean hasformula()
          true if all cells in the range contain formulas;
 boolean hasformulaarray()
          determines if all cells in the range contain array-entered formula.
 boolean hasformulaboolvalue()
          determines if all cells in the range contain formula bool value..
 boolean hasformuladatetime()
          indicates if current range has formula value formatted as datetime.
 boolean hasformulaerrorvalue()
          determines if all cells in the range contain error value.
 boolean hasformulanumbervalue()
          indicates whether current range has formula number value.
 boolean hasformulastringvalue()
          indicates whether current range contains formula value which evaluated as string.
 boolean hasmerged()
          indicates whether this range is part of merged range.
 boolean hasnumber()
          determines if any one cell in the range contain number.
 boolean haspictures()
          indicates whether the range is blank.
 boolean hasrichtext()
          determines if all cells in the range contain rich text string.
 boolean hasstring()
          determines if all cells in the range contain string.
 boolean hasstyle()
          determines if all cells in the range contain differs from default style.
 ixlsrange intersect(ixlsrange range)
          returns intersection of this range with the specified one.
 boolean isallnumber()
          determines if all cells in the range contain number.
 boolean isblank()
          indicates whether the range is blank.
 boolean isformulahidden()
          determines if the formula will be hidden when the worksheet is protected.
 void isformulahidden(boolean value)
           
 boolean isgroupedbycolumn()
          indicates whether this range is grouped by column.
 boolean isgroupedbyrow()
          indicates whether this range is grouped by row.
 boolean isinitialized()
          indicates whether range has been initialized.
 java.lang.boolean isstringspreserved()
          indicates whether all values in the range are preserved as strings.
 void isstringspreserved(java.lang.boolean value)
          indicates whether all values in the range are preserved as strings.
 boolean iswraptext()
          determines if microsoft excel wraps the text in the object.
 void iswraptext(boolean value)
          true if microsoft excel wraps the text in the object.
 java.util.iterator iterator()
           
 java.awt.geom.dimension2d measurestring(java.lang.string measurestring)
          measures size of the string.
 void merge()
          creates a merged cell from the specified range object.
 void merge(boolean clearcells)
          creates a merged cell from the specified range object.
 ixlsrange merge(ixlsrange range)
          creates a merged cell from the specified range object.
 void partialclear()
          partially clear range.
 void replace(java.lang.string oldvalue, datacolumn newvalues, boolean isfieldnamesshown)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, datatable newvalues, boolean isfieldnamesshown)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, java.util.date newvalue)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, double newvalue)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, double[] newvalues, boolean isvertical)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, int[] newvalues, boolean isvertical)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, java.lang.string newvalue)
          replaces cells' values with new data.
 void replace(java.lang.string oldvalue, java.lang.string[] newvalues, boolean isvertical)
          replaces cells' values with new data.
 void set(int row, int column, ixlsrange value)
          sets cell by row and column index.
 void setbooleanvalue(boolean value)
          returns or sets the bool value of the specified range.
 void setbuiltinstyle(builtinstyles value)
          gets/sets built in style.
 void setcellstylename(java.lang.string cellstylename)
          sets name of the style for the current range.
 void setcolumnwidth(double columnwidth)
          sets the width of the column.
 void setdatavalidation(xlsvalidation dv)
          sets data validation for the range.
 void setdatetimevalue(java.util.calendar calendar)
          sets calendar value of the range.
 void setdatetimevalue(java.util.date date)
          sets date value of the range.
 void seterrorvalue(java.lang.string value)
          gets or sets error value of this range.
 void setextendedformatindex(int value)
          sets / gets index of extended format.
 void setextendedformatindexs(int index)
          sets index of extended format that defines style for this range..
 void setformula(java.lang.string formula)
          sets the object's formula in a1-style notation and in the language of the macro.
 void setformulaarray(java.lang.string value)
          returns or sets the array formula of a range.
 void setformulaarrayr1c1(java.lang.string value)
          returns or sets the formula for the object, using r1c1-style notation in the language of the macro
 void setformulaboolvalue(boolean value)
          gets or sets bool value of the formula.
 void setformuladatetime(java.util.date value)
          gets or sets bool value of the formula.
 void setformulaerrorvalue(java.lang.string value)
          sets the error value of the formula.
 void setformulanumbervalue(double value)
          gets or sets double value of the formula.
 void setformular1c1(java.lang.string value)
          returns or sets the formula for the object, using r1c1-style notation in the language of the macro
 void setformulastringvalue(java.lang.string value)
          gets or sets string value of the range.
 void sethorizontalalignment(horizontalaligntype value)
          returns or sets the horizontal alignment for the specified object.
 void sethtmlstring(java.lang.string value)
          sets the html string which contains data and some formattings in this cell.
 void setignoreerroroptions(java.util.enumset<ignoreerrortype> ignoreerroroptions)
          sets ignore error options.
 void setindentlevel(int value)
          returns or sets the indent level for the cell or range.
 void setlastcolumn(int value)
          gets or sets last column of the range.
 void setlastrow(int value)
          gets or sets last row of the range.
 void setnumberformat(java.lang.string numberformat)
          sets number format
 void setnumbervalue(double numbervalue)
          sets number value
 void setobjectvalue(java.lang.object value)
          sets the cell value.
 void setrowheight(double rowheight)
          sets the height of the row
 void setrowheight(double rowheight, boolean bisbadfontheight)
          sets row height.
 void setstyle(istyle value)
          returns a style object that represents the style of the specified range.
 void settext(java.lang.string text)
          sets text
 void setvalue(java.lang.string value)
          sets the value of the specified range.
 void setverticalalignment(verticalaligntype value)
          returns or sets the vertical alignment of the specified object.
 cellrange ungroupbycolumns()
          ungroups column.
 cellrange ungroupbyrows()
          ungroups row.
 void unmerge()
          separates a merged area into individual cells.
 void updaterange(int startrow, int startcolumn, int endrow, int endcolumn)
          update region of range
 
methods inherited from interface com.spire.xls.core.icombinedrange
getrectanglescount
 
methods inherited from interface com.spire.xls.core.ixlsrange
expandgroup, getinnerformuladatetime, gettimespanvalue
 
constructor detail

xlsrange

public xlsrange(java.lang.object parent)

xlsrange

public xlsrange(java.lang.object parent,
                int column,
                int row)

xlsrange

public xlsrange(java.lang.object parent,
                int firstcol,
                int firstrow,
                int lastcol,
                int lastrow)
method detail

getbooleanvalue

public boolean getbooleanvalue()
returns or sets the bool value of the specified range.
specified by:
getbooleanvalue in interface ixlsrange

setbooleanvalue

public void setbooleanvalue(boolean value)
returns or sets the bool value of the specified range.
specified by:
setbooleanvalue in interface ixlsrange
parameters:
value -

getborders

public iborders getborders()
returns a borders collection that represents the borders of a style or a range of cells (including a range defined as part of a conditional format).
specified by:
getborders in interface ixlsrange

getbuiltinstyle

public builtinstyles getbuiltinstyle()
gets/sets built in style.
specified by:
getbuiltinstyle in interface ixlsrange

setbuiltinstyle

public void setbuiltinstyle(builtinstyles value)
gets/sets built in style.
specified by:
setbuiltinstyle in interface ixlsrange

getcelllist

public java.util.arraylist<cellrange> getcelllist()
returns a range object that represents the cells in the specified range.
specified by:
getcelllist in interface ixlsrange

getcellstylename

public java.lang.string getcellstylename()
gets/sets name of the style for the current range.
specified by:
getcellstylename in interface ixlsrange

setcellstylename

public void setcellstylename(java.lang.string cellstylename)
sets name of the style for the current range.
parameters:
cellstylename -

getcolumn

public int getcolumn()
returns the number of the first column in the first area in the specified range.
specified by:
getcolumn in interface ixlsrange

getcolumngrouplevel

public int getcolumngrouplevel()
column group level.
specified by:
getcolumngrouplevel in interface ixlsrange

getcolumns

public ixlsrange[] getcolumns()
for a range object, it returns an array of range objects that represent the columns in the specified range.
specified by:
getcolumns in interface ixlsrange

getcolumnwidth

public double getcolumnwidth()
returns or sets the width of all columns in the specified range.
specified by:
getcolumnwidth in interface ixlsrange

setcolumnwidth

public void setcolumnwidth(double columnwidth)
sets the width of the column.
parameters:
columnwidth -

getcomment

public icommentshape getcomment()
returns a comment object that represents the comment associated with the cell in the upper-left corner of the range.
specified by:
getcomment in interface ixlsrange

getconditionalformats

public conditionalformats getconditionalformats()
collection of conditional formats for the range.
specified by:
getconditionalformats in interface ixlsrange

getcount

public int getcount()
returns the number of objects in the collection.
specified by:
getcount in interface ixlsrange

getdatavalidation

public validation getdatavalidation()
gets datavalidation of the sheet. read only
specified by:
getdatavalidation in interface ixlsrange

getdatetimevalue

public java.util.date getdatetimevalue()
gets datetime value of the range.
specified by:
getdatetimevalue in interface ixlsrange

setdatetimevalue

public void setdatetimevalue(java.util.date date)
sets date value of the range.

setdatetimevalue

public void setdatetimevalue(java.util.calendar calendar)
sets calendar value of the range.

getendcell

public ixlsrange getendcell()
returns a range object that represents the cell at the end of the region that contains the source range.
specified by:
getendcell in interface ixlsrange

getentirecolumn

public ixlsrange getentirecolumn()
returns a range object that represents the entire column (or columns) that contains the specified range.
specified by:
getentirecolumn in interface ixlsrange

getentirerow

public ixlsrange getentirerow()
returns a range object that represents the entire row (or rows) that contains the specified range. read-only.
specified by:
getentirerow in interface ixlsrange

getenvalutedvalue

public java.lang.string getenvalutedvalue()
returns the calculated value of a formula.
specified by:
getenvalutedvalue in interface ixlsrange

geterrorvalue

public java.lang.string geterrorvalue()
gets or sets error value of this range.
specified by:
geterrorvalue in interface ixlsrange

seterrorvalue

public void seterrorvalue(java.lang.string value)
gets or sets error value of this range.
parameters:
value -

getformula

public java.lang.string getformula()
returns the object's formula in a1-style notation and in the language of the macro.
specified by:
getformula in interface ixlsrange

setformula

public void setformula(java.lang.string formula)
sets the object's formula in a1-style notation and in the language of the macro. write variant.
parameters:
formula -

getformulaarray

public java.lang.string getformulaarray()
returns or sets the array formula of a range.
specified by:
getformulaarray in interface ixlsrange

setformulaarray

public void setformulaarray(java.lang.string value)
returns or sets the array formula of a range.
parameters:
value -

getformulaarrayr1c1

public java.lang.string getformulaarrayr1c1()
returns or sets the formula for the object, using r1c1-style notation in the language of the macro
specified by:
getformulaarrayr1c1 in interface ixlsrange

setformulaarrayr1c1

public void setformulaarrayr1c1(java.lang.string value)
returns or sets the formula for the object, using r1c1-style notation in the language of the macro
parameters:
value -

getformulaboolvalue

public boolean getformulaboolvalue()
gets or sets bool value of the formula.
specified by:
getformulaboolvalue in interface ixlsrange

setformulaboolvalue

public void setformulaboolvalue(boolean value)
gets or sets bool value of the formula.
parameters:
value -

getformuladatetime

public java.util.date getformuladatetime()
gets or sets bool value of the formula.

setformuladatetime

public void setformuladatetime(java.util.date value)
gets or sets bool value of the formula.

getformulaerrorvalue

public java.lang.string getformulaerrorvalue()
gets or sets error value of the formula.
specified by:
getformulaerrorvalue in interface ixlsrange

setformulaerrorvalue

public void setformulaerrorvalue(java.lang.string value)
sets the error value of the formula.
parameters:
value -

getformulanumbervalue

public double getformulanumbervalue()
gets the double value of the formula.
specified by:
getformulanumbervalue in interface ixlsrange

setformulanumbervalue

public void setformulanumbervalue(double value)
gets or sets double value of the formula.
specified by:
setformulanumbervalue in interface ixlsrange
parameters:
value -

getformular1c1

public java.lang.string getformular1c1()
returns or sets the formula for the object, using r1c1-style notation in the language of the macro
specified by:
getformular1c1 in interface ixlsrange

setformular1c1

public void setformular1c1(java.lang.string value)
returns or sets the formula for the object, using r1c1-style notation in the language of the macro
parameters:
value -

getformulastringvalue

public java.lang.string getformulastringvalue()
gets or sets string value of the range.
specified by:
getformulastringvalue in interface ixlsrange

setformulastringvalue

public void setformulastringvalue(java.lang.string value)
gets or sets string value of the range.
specified by:
setformulastringvalue in interface ixlsrange
parameters:
value -

getformulavalue

public java.lang.object getformulavalue()
gets formula value.

hasboolean

public boolean hasboolean()
indicates whether range contains bool value.
specified by:
hasboolean in interface ixlsrange

hascomment

public boolean hascomment()

getcolumncount

public int getcolumncount()
gets number of columns.

getrowcount

public int getrowcount()
gets number of rows.

hasdatavalidation

public boolean hasdatavalidation()
indicates whether specified range object has data validation. if range is not single cell, then returns true only if all cells have data validation. read-only.
specified by:
hasdatavalidation in interface ixlsrange

hasdatetime

public boolean hasdatetime()
determines if all cells in the range contain datetime.
specified by:
hasdatetime in interface ixlsrange

haserror

public boolean haserror()
indicates whether range contains error value.
specified by:
haserror in interface ixlsrange

hasexternalformula

public boolean hasexternalformula()
check if the formula in the range has external links. read-only.
specified by:
hasexternalformula in interface ixlsrange

hasformula

public boolean hasformula()
true if all cells in the range contain formulas;
specified by:
hasformula in interface ixlsrange

hasformulaarray

public boolean hasformulaarray()
determines if all cells in the range contain array-entered formula.
specified by:
hasformulaarray in interface ixlsrange

hasformulaboolvalue

public boolean hasformulaboolvalue()
determines if all cells in the range contain formula bool value..
specified by:
hasformulaboolvalue in interface ixlsrange

hasformuladatetime

public boolean hasformuladatetime()
indicates if current range has formula value formatted as datetime. read-only.
specified by:
hasformuladatetime in interface ixlsrange

hasformulaerrorvalue

public boolean hasformulaerrorvalue()
determines if all cells in the range contain error value.
specified by:
hasformulaerrorvalue in interface ixlsrange

hasformulanumbervalue

public boolean hasformulanumbervalue()
indicates whether current range has formula number value.
specified by:
hasformulanumbervalue in interface ixlsrange

hasformulastringvalue

public boolean hasformulastringvalue()
indicates whether current range contains formula value which evaluated as string.
specified by:
hasformulastringvalue in interface ixlsrange

hasmerged

public boolean hasmerged()
indicates whether this range is part of merged range.
specified by:
hasmerged in interface ixlsrange

hasnumber

public boolean hasnumber()
determines if any one cell in the range contain number.
specified by:
hasnumber in interface ixlsrange

haspictures

public boolean haspictures()
indicates whether the range is blank.

hasrichtext

public boolean hasrichtext()
determines if all cells in the range contain rich text string.
specified by:
hasrichtext in interface ixlsrange

hasstring

public boolean hasstring()
determines if all cells in the range contain string.
specified by:
hasstring in interface ixlsrange

hasstyle

public boolean hasstyle()
determines if all cells in the range contain differs from default style.
specified by:
hasstyle in interface ixlsrange

gethorizontalalignment

public horizontalaligntype gethorizontalalignment()
returns or sets the horizontal alignment for the specified object.
specified by:
gethorizontalalignment in interface ixlsrange

sethorizontalalignment

public void sethorizontalalignment(horizontalaligntype value)
returns or sets the horizontal alignment for the specified object.

gethyperlinks

public ihyperlinks gethyperlinks()
returns hyperlinks for this range.

getignoreerroroptions

public java.util.enumset<ignoreerrortype> getignoreerroroptions()
represents ignore error options. if not single cell returs concatenateed flags.
specified by:
getignoreerroroptions in interface ixlsrange
returns:

setignoreerroroptions

public void setignoreerroroptions(java.util.enumset<ignoreerrortype> ignoreerroroptions)
sets ignore error options. if not single cell returns concatenateed flags.
specified by:
setignoreerroroptions in interface ixlsrange

getindentlevel

public int getindentlevel()
returns or sets the indent level for the cell or range. value should be 0 between 15.
specified by:
getindentlevel in interface ixlsrange

setindentlevel

public void setindentlevel(int value)
returns or sets the indent level for the cell or range. value should be 0 between 15.

isallnumber

public boolean isallnumber()
determines if all cells in the range contain number.

isblank

public boolean isblank()
indicates whether the range is blank.
specified by:
isblank in interface ixlsrange

isformulahidden

public boolean isformulahidden()
determines if the formula will be hidden when the worksheet is protected.
specified by:
isformulahidden in interface ixlsrange

isformulahidden

public void isformulahidden(boolean value)

isgroupedbycolumn

public boolean isgroupedbycolumn()
indicates whether this range is grouped by column.
specified by:
isgroupedbycolumn in interface ixlsrange

isgroupedbyrow

public boolean isgroupedbyrow()
indicates whether this range is grouped by row.
specified by:
isgroupedbyrow in interface ixlsrange

isinitialized

public boolean isinitialized()
indicates whether range has been initialized.
specified by:
isinitialized in interface ixlsrange

isstringspreserved

public java.lang.boolean isstringspreserved()
indicates whether all values in the range are preserved as strings.
specified by:
isstringspreserved in interface ixlsrange

isstringspreserved

public void isstringspreserved(java.lang.boolean value)
indicates whether all values in the range are preserved as strings.
specified by:
isstringspreserved in interface ixlsrange

iswraptext

public boolean iswraptext()
determines if microsoft excel wraps the text in the object.
specified by:
iswraptext in interface ixlsrange

iswraptext

public void iswraptext(boolean value)
description copied from interface: ixlsrange
true if microsoft excel wraps the text in the object. read/write boolean.
specified by:
iswraptext in interface ixlsrange

getlastcolumn

public int getlastcolumn()
gets or sets last column of the range.
specified by:
getlastcolumn in interface ixlsrange

setlastcolumn

public void setlastcolumn(int value)
gets or sets last column of the range.

getlastrow

public int getlastrow()
gets or sets last row of the range.
specified by:
getlastrow in interface ixlsrange

setlastrow

public void setlastrow(int value)
gets or sets last row of the range.

getmergearea

public ixlsrange getmergearea()
returns a range object that represents the merged range containing the specified cell.
specified by:
getmergearea in interface ixlsrange

getdisplayedtext

public java.lang.string getdisplayedtext()
gets cell displayed text.

hasconditionformats

public boolean hasconditionformats()
indicates whether each cell of the range has some conditional formatting.

getnumberformat

public java.lang.string getnumberformat()
returns or sets the format code for the object.
specified by:
getnumberformat in interface ixlsrange

setnumberformat

public void setnumberformat(java.lang.string numberformat)
sets number format

getnumbertext

public java.lang.string getnumbertext()
returns cell text for number format.
specified by:
getnumbertext in interface ixlsrange

getnumbervalue

public double getnumbervalue()
gets or sets number value of the range.
specified by:
getnumbervalue in interface ixlsrange

setnumbervalue

public void setnumbervalue(double numbervalue)
sets number value
parameters:
numbervalue -

getparent

public java.lang.object getparent()
parent object for this object.
overrides:
getparent in class xlsobject

getrangeaddress

public java.lang.string getrangeaddress()
returns the range reference in the language of the macro. read-only string.
specified by:
getrangeaddress in interface ixlsrange

getrangeaddresslocal

public java.lang.string getrangeaddresslocal()
returns the range reference for the specified range in the language of the user.
specified by:
getrangeaddresslocal in interface ixlsrange

getrangeglobaladdresswithoutsheetname

public java.lang.string getrangeglobaladdresswithoutsheetname()
return global address without worksheet name.

getrangeglobaladdress

public java.lang.string getrangeglobaladdress()
returns the range reference in the language of the macro.
specified by:
getrangeglobaladdress in interface ixlsrange

getranger1c1address

public java.lang.string getranger1c1address()
returns the range reference using r1c1 notation.
specified by:
getranger1c1address in interface ixlsrange

getranger1c1addresslocal

public java.lang.string getranger1c1addresslocal()
returns the range reference using r1c1 notation.
specified by:
getranger1c1addresslocal in interface ixlsrange

getrichtext

public irichtextstring getrichtext()
returns a richtextstring object that represents the rich text style.
specified by:
getrichtext in interface ixlsrange

gethtmlstring

public java.lang.string gethtmlstring()
gets the html string which contains data and some formattings in this cell.
specified by:
gethtmlstring in interface ixlsrange
returns:

sethtmlstring

public void sethtmlstring(java.lang.string value)
sets the html string which contains data and some formattings in this cell.
specified by:
sethtmlstring in interface ixlsrange
parameters:
value -

getrow

public int getrow()
returns the number of the first row of the first area in the range.
specified by:
getrow in interface ixlsrange

getrowgrouplevel

public int getrowgrouplevel()
row group level.
specified by:
getrowgrouplevel in interface ixlsrange

getrowheight

public double getrowheight()
returns the height of all the rows in the range specified, measured in points.
specified by:
getrowheight in interface ixlsrange

setrowheight

public void setrowheight(double rowheight)
sets the height of the row
parameters:
rowheight -

getrows

public ixlsrange[] getrows()
for a range object, it returns an array of range objects that represent the rows in the specified range.
specified by:
getrows in interface ixlsrange

getextendedformatindex

public int getextendedformatindex()
sets / gets index of extended format.
throws:
"system.argumentexception" - when method is applied for the range that contains more than one cell.

setextendedformatindex

public void setextendedformatindex(int value)
sets / gets index of extended format.
parameters:
value -

setextendedformatindexs

public void setextendedformatindexs(int index)
sets index of extended format that defines style for this range..
parameters:
index - index to set.

setrowheight

public void setrowheight(double rowheight,
                         boolean bisbadfontheight)
sets row height.
parameters:
rowheight - row height
bisbadfontheight - indicates whether font and row height are not compatible.

getstyle

public istyle getstyle()
returns a style object that represents the style of the specified range.
specified by:
getstyle in interface ixlsrange

setstyle

public void setstyle(istyle value)
returns a style object that represents the style of the specified range.

gettext

public java.lang.string gettext()
gets / sets text of range.
specified by:
gettext in interface ixlsrange

settext

public void settext(java.lang.string text)
sets text
parameters:
text -

get

public ixlsrange get(int row,
                     int column,
                     int lastrow,
                     int lastcolumn)
get cell range. row and column indexes are one-based. read-only.
specified by:
get in interface ixlsrange

get

public ixlsrange get(int row,
                     int column)
gets / sets cell by row and column index. row and column indexes are one-based.
specified by:
get in interface ixlsrange

set

public void set(int row,
                int column,
                ixlsrange value)
description copied from interface: ixlsrange
sets cell by row and column index. row and column indexes are one-based.
specified by:
set in interface ixlsrange

get

public ixlsrange get(java.lang.string name,
                     boolean isr1c1notation)
gets cell range. read-only.
specified by:
get in interface ixlsrange

get

public ixlsrange get(java.lang.string name)
gets cell range. read-only.
specified by:
get in interface ixlsrange

getvalue

public java.lang.string getvalue()
returns the value of the specified range.
specified by:
getvalue in interface ixlsrange

setvalue

public void setvalue(java.lang.string value)
sets the value of the specified range. write variant.
specified by:
setvalue in interface ixlsrange

getvalue2

public java.lang.object getvalue2()
returns or sets the cell value. it's not use for current and datetime types.
specified by:
getvalue2 in interface ixlsrange
returns:

setobjectvalue

public void setobjectvalue(java.lang.object value)
sets the cell value. it's not use for current and datetime types.
specified by:
setobjectvalue in interface ixlsrange

getverticalalignment

public verticalaligntype getverticalalignment()
returns or sets the vertical alignment of the specified object.
specified by:
getverticalalignment in interface ixlsrange

setverticalalignment

public void setverticalalignment(verticalaligntype value)
returns or sets the vertical alignment of the specified object.
specified by:
setverticalalignment in interface ixlsrange

getworksheet

public iworksheet getworksheet()
returns a worksheet object that represents the worksheet containing the specified range.
specified by:
getworksheet in interface ixlsrange

getnewrangelocation

public java.lang.string getnewrangelocation(java.util.hashmap names,
                                            java.lang.string[] sheetname)
gets new range location.
specified by:
getnewrangelocation in interface icombinedrange
parameters:
names - worksheet names.
sheetname - new worksheet name.
returns:
new name.

deepclone

public ixlsrange deepclone(java.lang.object parent,
                           java.util.hashmap rangenames,
                           xlsworkbook book)
clones current ixlsrange.
specified by:
deepclone in interface icombinedrange
parameters:
parent - parent object.
rangenames - hash table with new names.
book - parent workbook.
returns:
returns clone of current instance.

clearconditionalformats

public void clearconditionalformats()
clears conditional formats.
specified by:
clearconditionalformats in interface icombinedrange

getrectangles

public java.awt.rectangle[] getrectangles()
gets rectangle information of current range.
specified by:
getrectangles in interface icombinedrange
returns:
rectangles information

getworksheetname

public java.lang.string getworksheetname()
returns name of the parent worksheet.
specified by:
getworksheetname in interface icombinedrange

getcellscount

public int getcellscount()
gets number of cells.
specified by:
getcellscount in interface icombinedrange

getrangeglobaladdress2007

public java.lang.string getrangeglobaladdress2007()
gets address global in the format required by excel 2007.
specified by:
getrangeglobaladdress2007 in interface icombinedrange

activate

public ixlsrange activate(boolean scroll)
activates a single cell, scroll to it and activates the corresponding sheet. to select a range of cells, use the select method.
specified by:
activate in interface ixlsrange
parameters:
scroll - true to scroll to the cell
returns:

activate

public ixlsrange activate()
active single cell in the worksheet
returns:

addcomment

public icommentshape addcomment()
adds a comment to the range.
specified by:
addcomment in interface ixlsrange
returns:
created comment or exists one.

autofitcolumns

public void autofitcolumns()
changes the width of the columns in the range to achieve the best fit.
specified by:
autofitcolumns in interface ixlsrange

autofitrows

public void autofitrows()
automatically adjust the height and width of the rows
specified by:
autofitrows in interface ixlsrange

borderaround

public void borderaround()
sets around border for current range.
specified by:
borderaround in interface ixlsrange

borderaround

public void borderaround(linestyletype borderline)
sets around border for current range.
specified by:
borderaround in interface ixlsrange
parameters:
borderline - represents border line.

borderaround

public void borderaround(linestyletype borderline,
                         java.awt.color bordercolor)
sets around border for current range.
specified by:
borderaround in interface ixlsrange
parameters:
borderline - represents border line.
bordercolor - represents border color.

borderaround

public void borderaround(linestyletype borderline,
                         excelcolors bordercolor)
sets around border for current range.
specified by:
borderaround in interface ixlsrange
parameters:
borderline - represents border line.
bordercolor - represents border color as excelcolors.

borderinside

public void borderinside()
sets inside border for current range.
specified by:
borderinside in interface ixlsrange

borderinside

public void borderinside(linestyletype borderline)
sets inside border for current range.
specified by:
borderinside in interface ixlsrange
parameters:
borderline - represents border line.

borderinside

public void borderinside(linestyletype borderline,
                         java.awt.color bordercolor)
sets inside border for current range.
specified by:
borderinside in interface ixlsrange
parameters:
borderline - sets inside border for current range.
bordercolor - represents border color.

borderinside

public void borderinside(linestyletype borderline,
                         excelcolors bordercolor)
sets inside border for current range.
specified by:
borderinside in interface ixlsrange
parameters:
borderline - represents border line.
bordercolor - represents border color as excelcolors.

bordernone

public void bordernone()
sets none border for current range.
specified by:
bordernone in interface ixlsrange

clear

public void clear(excelclearoptions option)
clears the cell based on clear options.
specified by:
clear in interface ixlsrange
parameters:
option -

clearall

public void clearall()
clears the entire object.

clearcontents

public void clearcontents()
clear the contents of the range.
specified by:
clearcontents in interface ixlsrange

groupbycolumns

public cellrange groupbycolumns(boolean iscollapsed)
groups columns.
parameters:
iscollapsed - indicates whether group should be collapsed.
returns:

groupbyrows

public cellrange groupbyrows(boolean iscollapsed)
groups row.
parameters:
iscollapsed - indicates whether group should be collapsed.
returns:

ungroupbycolumns

public cellrange ungroupbycolumns()
ungroups column.
returns:

ungroupbyrows

public cellrange ungroupbyrows()
ungroups row.
returns:

collapsegroup

public void collapsegroup(groupbytype groupby)
collapses current group.
specified by:
collapsegroup in interface ixlsrange
parameters:
groupby - this parameter specifies whether the grouping should be performed by rows or by columns.

dispose

public void dispose()
this method is called when disposing the object.
overrides:
dispose in class xlsobject

expandgroup

public void expandgroup(groupbytype groupby)
expands current group.
specified by:
expandgroup in interface ixlsrange
parameters:
groupby - this parameter specifies whether the grouping should be performed by rows or by columns.

freezepanes

public void freezepanes()
freezes panes at the current range in the worksheet. current range should be single cell range.
specified by:
freezepanes in interface ixlsrange

merge

public ixlsrange merge(ixlsrange range)
creates a merged cell from the specified range object.
specified by:
merge in interface ixlsrange
parameters:
range - the range to merge with.
returns:
merged ranges or null if wasn't able to merge ranges.

intersect

public ixlsrange intersect(ixlsrange range)
returns intersection of this range with the specified one.
specified by:
intersect in interface ixlsrange
parameters:
range - the range with which to intersect.
returns:
range intersection. if there is no intersection, null is returned.

measurestring

public java.awt.geom.dimension2d measurestring(java.lang.string measurestring)
measures size of the string.
parameters:
measurestring - string to measure.
returns:
size of the string.

merge

public void merge()
creates a merged cell from the specified range object.
specified by:
merge in interface ixlsrange

merge

public void merge(boolean clearcells)
creates a merged cell from the specified range object.
specified by:
merge in interface ixlsrange
parameters:
clearcells - indicates whether to clear unnecessary cells.

partialclear

public void partialclear()
partially clear range.

unmerge

public void unmerge()
separates a merged area into individual cells.
specified by:
unmerge in interface ixlsrange

iterator

public java.util.iterator iterator()

addcomment

public icommentshape addcomment(boolean bisparseoptions)
adds a comment to the range.
parameters:
bisparseoptions -
returns:
created comment or exists one.

setdatavalidation

public void setdatavalidation(xlsvalidation dv)
sets data validation for the range.
parameters:
dv - data validation to set.

replace

public void replace(java.lang.string oldvalue,
                    java.lang.string[] newvalues,
                    boolean isvertical)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalues - the replacement value.
isvertical - indicates whether to insert values vertically or horizontally.

replace

public void replace(java.lang.string oldvalue,
                    java.lang.string newvalue)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalue - the replacement value.

replace

public void replace(java.lang.string oldvalue,
                    double[] newvalues,
                    boolean isvertical)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalues - datacolumn to replace.
isvertical - indicates whether to insert values vertically or horizontally.

replace

public void replace(java.lang.string oldvalue,
                    int[] newvalues,
                    boolean isvertical)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalues - the replacement value.
isvertical - indicates whether to insert values vertically or horizontally.

replace

public void replace(java.lang.string oldvalue,
                    datatable newvalues,
                    boolean isfieldnamesshown)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalues - the replacement value.
isfieldnamesshown - indicates whether to insert values vertically or horizontally.

replace

public void replace(java.lang.string oldvalue,
                    java.util.date newvalue)
replaces cells' values with new data.
parameters:
oldvalue - value to search for
newvalue - the replacement value.

replace

public void replace(java.lang.string oldvalue,
                    double newvalue)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalue -

replace

public void replace(java.lang.string oldvalue,
                    datacolumn newvalues,
                    boolean isfieldnamesshown)
replaces cells' values with new data.
parameters:
oldvalue - value to search for.
newvalues - datacolumn to replace.
isfieldnamesshown - indicates whether to insert values vertically or horizontally.

addcombinedrange

public cellrange addcombinedrange(cellrange cr)
add combined range
parameters:
cr - cell range
returns:
cell range

updaterange

public void updaterange(int startrow,
                        int startcolumn,
                        int endrow,
                        int endcolumn)
update region of range
parameters:
startrow - first row
startcolumn - last row
endrow - last column
endcolumn - endcolumn

converttonumber

public void converttonumber()
convert number that stored as text to number


网站地图