Example:
//Instantiating a Workbook object $workbook = new cells\Workbook(); //Accessing the first worksheet in the Excel file $worksheet = $workbook->getWorksheets()->get(0); //Creating a named range $range = $worksheet->getCells()->createRange("B4", "G14"); //Setting the name of the named range $range->setName("TestRange");
Property Getters/Setters Summary | ||
---|---|---|
function | getComment() | |
function | setComment(value) | |
Gets and sets the commont of the name. Only applies for Excel 2007. | ||
function | getFullText() | |
Gets the name full text of the object with the scope setting. | ||
function | isReferred() | |
Indicates whether this name is referred by other formulas. | ||
function | isVisible() | |
function | setVisible(value) | |
Indicates whether the name is visible. | ||
function | getR1C1RefersTo() | |
function | setR1C1RefersTo(value) | |
Gets or sets a R1C1 reference of the |
||
function | getRefersTo() | |
function | setRefersTo(value) | |
Returns or sets the formula that the name is defined to refer to, beginning with an equal sign. | ||
function | getSheetIndex() | |
function | setSheetIndex(value) | |
Indicates this name belongs to Workbook or Worksheet. 0 = Global name, otherwise index to sheet (one-based) | ||
function | getText() | |
function | setText(value) | |
Gets the name text of the object. |
Method Summary | ||
---|---|---|
function | getRange() | |
Gets the range if this name refers to a range. | ||
function | getRange(recalculate) | |
Gets the range if this name refers to a range | ||
function | getRange(sheetIndex, row, column) | |
Gets the range if this name refers to a range. If the reference of this name is not absolute, the range may be different for different cell. | ||
function | getRanges() | |
Gets all ranges referred by this name. | ||
function | getRanges(recalculate) | |
Gets all ranges referred by this name. | ||
function | getReferredAreas(recalculate) | |
Gets all references referred by this name. | ||
function | getRefersTo(isR1C1, isLocal) | |
Get the reference of this Name. | ||
function | setRefersTo(refersTo, isR1C1, isLocal) | |
Set the reference of this Name. | ||
function | toString() | |
Returns a string represents the current Range object. |
Property Getters/Setters Detail |
---|
getComment/setComment : String | |
function getComment() / function setComment(value) |
getText/setText : String | |
function getText() / function setText(value) |
getFullText : String | |
function getFullText() |
getRefersTo/setRefersTo : String | |
function getRefersTo() / function setRefersTo(value) |
getR1C1RefersTo/setR1C1RefersTo : String | |
function getR1C1RefersTo() / function setR1C1RefersTo(value) |
isReferred : boolean | |
function isReferred() |
isVisible/setVisible : boolean | |
function isVisible() / function setVisible(value) |
getSheetIndex/setSheetIndex : Number | |
function getSheetIndex() / function setSheetIndex(value) |
Method Detail |
---|
getRefersTo | |
function getRefersTo(isR1C1, isLocal) |
isR1C1: boolean
- Whether the reference needs to be formatted as R1C1.isLocal: boolean
- Whether the reference needs to be formatted by locale.setRefersTo | |
function setRefersTo(refersTo, isR1C1, isLocal) |
refersTo: String
- The reference.isR1C1: boolean
- Whether the reference is R1C1 format.isLocal: boolean
- Whether the reference is locale formatted.toString | |
function toString() |
getRanges | |
function getRanges() |
getRanges | |
function getRanges(recalculate) |
recalculate: boolean
- whether recalcuate it if this name has been calcualted before this invocation.getReferredAreas | |
function getReferredAreas(recalculate) |
recalculate: boolean
- whether recalcuate it if this name has been calcualted before this invocation.getRange | |
function getRange() |
getRange | |
function getRange(recalculate) |
recalculate: boolean
- whether recalcuate it if this name has been calcualted before this invocation.getRange | |
function getRange(sheetIndex, row, column) |
sheetIndex: Number
- The according sheet index.row: Number
- The according row index.column: Number
- The according column index