# GC.Spread.Sheets.CellRange

## Content

# Class: CellRange

[Spread](../modules/GC.Spread).[Sheets](../modules/GC.Spread.Sheets).CellRange

## Table of contents

### Constructors

- [constructor](GC.Spread.Sheets.CellRange#constructor)

### Properties

- [col](GC.Spread.Sheets.CellRange#col)
- [colCount](GC.Spread.Sheets.CellRange#colcount)
- [row](GC.Spread.Sheets.CellRange#row)
- [rowCount](GC.Spread.Sheets.CellRange#rowcount)
- [sheet](GC.Spread.Sheets.CellRange#sheet)
- [sheetArea](GC.Spread.Sheets.CellRange#sheetarea)

### Methods

- [allowEditInCell](GC.Spread.Sheets.CellRange#alloweditincell)
- [altText](GC.Spread.Sheets.CellRange#alttext)
- [backColor](GC.Spread.Sheets.CellRange#backcolor)
- [backgroundImage](GC.Spread.Sheets.CellRange#backgroundimage)
- [backgroundImageLayout](GC.Spread.Sheets.CellRange#backgroundimagelayout)
- [bindingPath](GC.Spread.Sheets.CellRange#bindingpath)
- [borderBottom](GC.Spread.Sheets.CellRange#borderbottom)
- [borderLeft](GC.Spread.Sheets.CellRange#borderleft)
- [borderRight](GC.Spread.Sheets.CellRange#borderright)
- [borderTop](GC.Spread.Sheets.CellRange#bordertop)
- [cellButtons](GC.Spread.Sheets.CellRange#cellbuttons)
- [cellPadding](GC.Spread.Sheets.CellRange#cellpadding)
- [cellType](GC.Spread.Sheets.CellRange#celltype)
- [clear](GC.Spread.Sheets.CellRange#clear)
- [comment](GC.Spread.Sheets.CellRange#comment)
- [defaultValue](GC.Spread.Sheets.CellRange#defaultvalue)
- [diagonalDown](GC.Spread.Sheets.CellRange#diagonaldown)
- [diagonalUp](GC.Spread.Sheets.CellRange#diagonalup)
- [dropDowns](GC.Spread.Sheets.CellRange#dropdowns)
- [font](GC.Spread.Sheets.CellRange#font)
- [fontFamily](GC.Spread.Sheets.CellRange#fontfamily)
- [fontSize](GC.Spread.Sheets.CellRange#fontsize)
- [fontStyle](GC.Spread.Sheets.CellRange#fontstyle)
- [fontWeight](GC.Spread.Sheets.CellRange#fontweight)
- [foreColor](GC.Spread.Sheets.CellRange#forecolor)
- [formatter](GC.Spread.Sheets.CellRange#formatter)
- [formula](GC.Spread.Sheets.CellRange#formula)
- [hAlign](GC.Spread.Sheets.CellRange#halign)
- [height](GC.Spread.Sheets.CellRange#height)
- [hidden](GC.Spread.Sheets.CellRange#hidden)
- [imeMode](GC.Spread.Sheets.CellRange#imemode)
- [isVerticalText](GC.Spread.Sheets.CellRange#isverticaltext)
- [labelOptions](GC.Spread.Sheets.CellRange#labeloptions)
- [locked](GC.Spread.Sheets.CellRange#locked)
- [mask](GC.Spread.Sheets.CellRange#mask)
- [quotePrefix](GC.Spread.Sheets.CellRange#quoteprefix)
- [resizable](GC.Spread.Sheets.CellRange#resizable)
- [setBorder](GC.Spread.Sheets.CellRange#setborder)
- [setStyle](GC.Spread.Sheets.CellRange#setstyle)
- [setStyleName](GC.Spread.Sheets.CellRange#setstylename)
- [showEllipsis](GC.Spread.Sheets.CellRange#showellipsis)
- [shrinkToFit](GC.Spread.Sheets.CellRange#shrinktofit)
- [tabStop](GC.Spread.Sheets.CellRange#tabstop)
- [tag](GC.Spread.Sheets.CellRange#tag)
- [text](GC.Spread.Sheets.CellRange#text)
- [textDecoration](GC.Spread.Sheets.CellRange#textdecoration)
- [textDirection](GC.Spread.Sheets.CellRange#textdirection)
- [textIndent](GC.Spread.Sheets.CellRange#textindent)
- [textOrientation](GC.Spread.Sheets.CellRange#textorientation)
- [themeFont](GC.Spread.Sheets.CellRange#themefont)
- [toHtml](GC.Spread.Sheets.CellRange#tohtml)
- [vAlign](GC.Spread.Sheets.CellRange#valign)
- [validator](GC.Spread.Sheets.CellRange#validator)
- [value](GC.Spread.Sheets.CellRange#value)
- [visible](GC.Spread.Sheets.CellRange#visible)
- [watermark](GC.Spread.Sheets.CellRange#watermark)
- [width](GC.Spread.Sheets.CellRange#width)
- [wordWrap](GC.Spread.Sheets.CellRange#wordwrap)

## Constructors

### <a id="constructor" name="constructor"></a> constructor

• **new CellRange**(`sheet`, `row`, `col`, `rowCount?`, `colCount?`, `sheetArea?`)

Represents a cell range in a sheet.

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `sheet` | [`Worksheet`](GC.Spread.Sheets.Worksheet) | The sheet that contains this cell range. |
| `row` | `number` | The row index of the cell. |
| `col` | `number` | The column index of the cell. |
| `rowCount?` | `number` | - |
| `colCount?` | `number` | - |
| `sheetArea?` | [`SheetArea`](../enums/GC.Spread.Sheets.SheetArea) | - |

## Properties

### <a id="col" name="col"></a> col

• **col**: `number`

Gets the starting column index.

___

### <a id="colcount" name="colcount"></a> colCount

• **colCount**: `number`

Gets the column count.

___

### <a id="row" name="row"></a> row

• **row**: `number`

Gets the starting row index.

___

### <a id="rowcount" name="rowcount"></a> rowCount

• **rowCount**: `number`

Gets the row count.

___

### <a id="sheet" name="sheet"></a> sheet

• **sheet**: [`Worksheet`](GC.Spread.Sheets.Worksheet)

Gets the sheet that contains this cell range.

___

### <a id="sheetarea" name="sheetarea"></a> sheetArea

• **sheetArea**: [`SheetArea`](../enums/GC.Spread.Sheets.SheetArea)

Gets the area that contains this cell range.

## Methods

### <a id="alloweditincell" name="alloweditincell"></a> allowEditInCell

▸ **allowEditInCell**(`value?`): `any`

Gets or sets whether the cell can enter edit mode for editing.

**`example`**
```javascript
activeSheet.getRange(0, 0, 2, 3, GC.Spread.Sheets.SheetArea.viewport).allowEditInCell(false);
```

**`example`**
```javascript
activeSheet.getCell(1,1).allowEditInCell(false);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell can enter edit mode for editing; otherwise, returns the cell.

___

### <a id="alttext" name="alttext"></a> altText

▸ **altText**(`value?`): `any`

Gets or sets the alternative text of the cell for screen readers.

**`example`**
```javascript
var SpreadIcon = {
    FolderOpen: '\ue685',
    InfoFilled: '\ue718',
    Library: '\ue69d',
    NotebookFilled: '\uD800\uDC0F',
    Browse: '\ue626'
};
activeSheet.getCell(1, 1).value(SpreadIcon.FolderOpen).altText("Folder Open Icon");

// Besides plain text, the alternative text could also contain placeholder {value} or {formatted}, which represents cell value or cell formatted value.
// For example, if the cell value is 1000, and the alt text is "Sales amount is {value}", the final accessible content should be "Sales amount is 1000".
activeSheet.getCell(1, 1).value(1000).altText("Sales amount is {value}");
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `value?` | `any` | The alternative text of the cell. |

#### Returns

`any`

If no value is set, returns the alternative text of the cell; otherwise, returns the cell.

___

### <a id="backcolor" name="backcolor"></a> backColor

▸ **backColor**(`value?`): `any`

Gets or sets the background color for the cell, such as "red", "#FFFF00", "rgb(255,0,0)", "Accent 5", and so on.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).backColor("pink");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` \| [`IGradientFill`](../interfaces/GC.Spread.Sheets.IGradientFill) \| [`IGradientPathFill`](../interfaces/GC.Spread.Sheets.IGradientPathFill) \| [`IPatternFill`](../interfaces/GC.Spread.Sheets.IPatternFill) |

#### Returns

`any`

If no value is set, returns the cell background color; otherwise, returns the cell.

___

### <a id="backgroundimage" name="backgroundimage"></a> backgroundImage

▸ **backgroundImage**(`value?`): `any`

Gets or sets the background image for the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).backgroundImage("images/example.jpg");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell background image; otherwise, returns the cell.

___

### <a id="backgroundimagelayout" name="backgroundimagelayout"></a> backgroundImageLayout

▸ **backgroundImageLayout**(`value?`): `any`

Gets or sets the background image layout for the cell.

**`example`**
```javascript
var layout = GC.Spread.Sheets.ImageLayout.stretch;
activeSheet.getRange(-1, 1, -1, 1, GC.Spread.Sheets.SheetArea.viewport).backgroundImageLayout(layout);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`ImageLayout`](../enums/GC.Spread.Sheets.ImageLayout) |

#### Returns

`any`

If no value is set, returns the cell background image layout; otherwise, returns the cell.

___

### <a id="bindingpath" name="bindingpath"></a> bindingPath

▸ **bindingPath**(`path?`): `any`

Gets or sets the binding path for cell binding.

**`example`**
```javascript
//This example uses the bindingPath method.
var test = {name: "John"};
activeSheet.getCell(0,0).bindingPath( "name");
activeSheet.setDataSource(new GC.Spread.Sheets.Bindings.CellBindingSource(test));
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `path?` | `string` | The binding path for cell binding. |

#### Returns

`any`

If no value is set, returns the binding path for cell binding; otherwise, returns the worksheet.

___

### <a id="borderbottom" name="borderbottom"></a> borderBottom

▸ **borderBottom**(`value?`): `any`

Gets or sets the bottom border of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderBottom(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell bottom border line; otherwise, returns the cell.

___

### <a id="borderleft" name="borderleft"></a> borderLeft

▸ **borderLeft**(`value?`): `any`

Gets or sets the left border of the cell.

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderLeft(new GC.Spread.Sheets.LineBorder("green", GC.Spread.Sheets.LineStyle.mediumDashed));
```

**`example`**
```javascript
activeSheet.getCell(1,1).borderLeft(new GC.Spread.Sheets.LineBorder("red", GC.Spread.Sheets.LineStyle.double));
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderLeft(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell left border line; otherwise, returns the cell.

___

### <a id="borderright" name="borderright"></a> borderRight

▸ **borderRight**(`value?`): `any`

Gets or sets the right border of the cell.

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderRight(new GC.Spread.Sheets.LineBorder("green", GC.Spread.Sheets.LineStyle.mediumDashed));
```

**`example`**
```javascript
activeSheet.getCell(1,1).borderRight(new GC.Spread.Sheets.LineBorder("red", GC.Spread.Sheets.LineStyle.double));
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderRight(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell right border line; otherwise, returns the cell.

___

### <a id="bordertop" name="bordertop"></a> borderTop

▸ **borderTop**(`value?`): `any`

Gets or sets the top border of the cell.

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderTop(new GC.Spread.Sheets.LineBorder("green", GC.Spread.Sheets.LineStyle.mediumDashed));
```

**`example`**
```javascript
activeSheet.getCell(1,1).borderTop(new GC.Spread.Sheets.LineBorder("red", GC.Spread.Sheets.LineStyle.double));
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderTop(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell top border line; otherwise, returns the cell.

___

### <a id="cellbuttons" name="cellbuttons"></a> cellButtons

▸ **cellButtons**(`value?`): `any`

Gets or sets the cellButtons of the cell.

**`example`**
```javascript
activeSheet.getRange(2,-1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).cellButtons([caption:"Text"]]);
```

**`example`**
```javascript
var cellButtons = activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).cellButtons();
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `value?` | [`ICellButton`](../interfaces/GC.Spread.Sheets.ICellButton)[] | the cellButtons of the cell. |

#### Returns

`any`

If no value is set, returns the cellButtons of the cell; otherwise, returns the cell.

___

### <a id="cellpadding" name="cellpadding"></a> cellPadding

▸ **cellPadding**(`value?`): `any`

Gets or sets the cell padding.

**`example`**
```javascript
// This example adds cell padding around the watermark.
var type = new GC.Spread.Sheets.Style();
type.watermark = "User name";
type.cellPadding = "20";
type.labelOptions = {alignment:GC.Spread.Sheets.LabelAlignment.topLeft, visibility: GC.Spread.Sheets.LabelVisibility.visible};
activeSheet.setStyle(0, 1, type);
activeSheet.getRange(0, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).height(60);
activeSheet.getRange(-1, 1, -1, 1).width(150);
var combo = new GC.Spread.Sheets.CellTypes.ComboBox();
combo.items([{ text: "Oranges", value: "11k" }, { text: "Apples", value: "15k" }, { text: "Grape", value: "100k" }]);
combo.editorValueType(GC.Spread.Sheets.CellTypes.EditorValueType.text);
activeSheet.setCellType(2, 1, combo, GC.Spread.Sheets.SheetArea.viewport);
activeSheet.getCell(2, 1, GC.Spread.Sheets.SheetArea.viewport).watermark("ComboBox Cell Type").cellPadding('10 10 20 10');
activeSheet.getCell(2, 1, GC.Spread.Sheets.SheetArea.viewport).labelOptions({alignment: GC.Spread.Sheets.LabelAlignment.bottomCenter, foreColor: 'yellowgreen', font: 'bold 15px Arial'});
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).height(60);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the value of the cell padding; otherwise, returns the cell.

___

### <a id="celltype" name="celltype"></a> cellType

▸ **cellType**(`value?`): `any`

Gets or sets the cell type of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 1, -1, 1, GC.Spread.Sheets.SheetArea.viewport).cellType(new GC.Spread.Sheets.CellTypes.CheckBox());
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`Base`](GC.Spread.Sheets.CellTypes.Base) |

#### Returns

`any`

If no value is set, returns the cell type; otherwise, returns the cell.

___

### <a id="clear" name="clear"></a> clear

▸ **clear**(`type`): `void`

Clears the specified area.

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `type` | [`StorageType`](../enums/GC.Spread.Sheets.StorageType) | The clear type. |

#### Returns

`void`

___

### <a id="comment" name="comment"></a> comment

▸ **comment**(`value?`): `any`

Gets or sets the comment for the cell.

**`example`**
```javascript
// This example creates a cell comment.
var comment = new GC.Spread.Sheets.Comments.Comment();
comment.text("new comment!");
comment.backColor("yellow");
comment.foreColor("green");
comment.displayMode(GC.Spread.Sheets.Comments.DisplayMode.alwaysShown);
activeSheet.getCell(5,5).comment(comment);
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `value?` | [`Comment`](GC.Spread.Sheets.Comments.Comment) | The comment to set in the cell. |

#### Returns

`any`

If no value is set, returns the comment in the cell; otherwise, returns the cell range.

___

### <a id="defaultvalue" name="defaultvalue"></a> defaultValue

▸ **defaultValue**(`value?`): `any`

Gets or sets the default value of the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).defaultValue(10);
activeSheet.getCell(1,3).defaultValue("=LastYear+1000");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `any` |

#### Returns

`any`

If no value is set, returns the cell default value; otherwise, returns the cell.

___

### <a id="diagonaldown" name="diagonaldown"></a> diagonalDown

▸ **diagonalDown**(`value?`): `any`

Gets or sets the diagonalDown of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).diagonalDown(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell diagonalDown line; otherwise, returns the cell.

___

### <a id="diagonalup" name="diagonalup"></a> diagonalUp

▸ **diagonalUp**(`value?`): `any`

Gets or sets the diagonalUp of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).diagonalUp(new GC.Spread.Sheets.LineBorder("blue", GC.Spread.Sheets.LineStyle.mediumDashed));
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`LineBorder`](GC.Spread.Sheets.LineBorder) |

#### Returns

`any`

If no value is set, returns the cell diagonalUp line; otherwise, returns the cell.

___

### <a id="dropdowns" name="dropdowns"></a> dropDowns

▸ **dropDowns**(`value?`): `any`

Gets or sets the dropDowns of the cell.

**`example`**
```javascript
activeSheet.getRange(2,-1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).dropDowns([caption:"Text"]]);
```

**`example`**
```javascript
var dropDowns = activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).dropDowns();
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`IDropdown`](../interfaces/GC.Spread.Sheets.IDropdown)[] |

#### Returns

`any`

If no value is set, returns the dropDowns of the cell; otherwise, returns the cell.

___

### <a id="font" name="font"></a> font

▸ **font**(`value?`): `any`

Gets or sets the font for the cell, such as "normal normal normal 20px/normal Arial".

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).font("12pt Arial");
```

**`example`**
```javascript
activeSheet.getCell(1,1).font("8pt Arial");
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).font("12pt Arial");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's font; otherwise, returns the cell.

___

### <a id="fontfamily" name="fontfamily"></a> fontFamily

▸ **fontFamily**(`value?`): `any`

Gets or sets the fontFamily for the cell, such as "Arial".

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).fontFamily("Arial");
```

**`example`**
```javascript
activeSheet.getCell(1,1).fontFamily("Arial");
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).fontFamily("Arial");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's fontFamily; otherwise, returns the cell.

___

### <a id="fontsize" name="fontsize"></a> fontSize

▸ **fontSize**(`value?`): `any`

Gets or sets the fontSize for the cell, such as "16px".

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).fontSize("16px");
```

**`example`**
```javascript
activeSheet.getCell(1,1).fontSize("16px");
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).fontSize("16px");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's fontSize; otherwise, returns the cell.

___

### <a id="fontstyle" name="fontstyle"></a> fontStyle

▸ **fontStyle**(`value?`): `any`

Gets or sets the fontStyle for the cell, such as "italic".

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).fontStyle("italic");
```

**`example`**
```javascript
activeSheet.getCell(1,1).fontStyle("italic");
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).fontStyle("italic");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's fontStyle; otherwise, returns the cell.

___

### <a id="fontweight" name="fontweight"></a> fontWeight

▸ **fontWeight**(`value?`): `any`

Gets or sets the fontWeight for the cell, such as "bold".

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).fontWeight("bold");
```

**`example`**
```javascript
activeSheet.getCell(1,1).fontWeight("bold");
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).fontWeight("bold");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's fontWeight; otherwise, returns the cell.

___

### <a id="forecolor" name="forecolor"></a> foreColor

▸ **foreColor**(`value?`): `any`

Gets or sets the color of the text in the cell, such as "red", "#FFFF00", "rgb(255,0,0)", "Accent 5", and so on.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).foreColor("blue");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell foreground color; otherwise, returns the cell.

___

### <a id="formatter" name="formatter"></a> formatter

▸ **formatter**(`value?`): `any`

Gets or sets the formatter for the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).formatter("0.000%");
```

**`example`**
```javascript
activeSheet.getCell(1, -1).formatter("0.000%");
activeSheet.getCell(1,0).value("2");
```

**`example`**
```javascript
activeSheet.getCell(-1, 0).formatter("0.000%");
activeSheet.getCell(0,0).value("2");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` \| [`GeneralFormatter`](GC.Spread.Formatter.GeneralFormatter) |

#### Returns

`any`

If no value is set, returns the cell formatter string or object; otherwise, returns the cell.

___

### <a id="formula" name="formula"></a> formula

▸ **formula**(`value?`, `autoAdjustReference?`): `any`

Gets or sets the formula for the cell.

**`example`**
```javascript
activeSheet.getCell(0,2).formula("DATEDIF(DATE(2003,1,1),DATE(2016,1,1),\"Y\")");
activeSheet.getRange(2,2,100,1).formula("=A3+$A$1"); // all the cells are "=A3+$A$1"
activeSheet.getRange(2,2,100,1).formula("=A3+$A$1", true); // the first cell is "=A3+$A$1", the second cell is "=A4+$A$1", ...
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |
| `autoAdjustReference?` | `boolean` |

#### Returns

`any`

If no value is set, returns the cell formula; otherwise, returns the cell.

___

### <a id="halign" name="halign"></a> hAlign

▸ **hAlign**(`value?`): `any`

Gets or sets the horizontal alignment of the contents of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).hAlign(GC.Spread.Sheets.HorizontalAlign.right);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`HorizontalAlign`](../enums/GC.Spread.Sheets.HorizontalAlign) |

#### Returns

`any`

If no value is set, returns the horizontal alignment of the contents of the cell; otherwise, returns the cell.

___

### <a id="height" name="height"></a> height

▸ **height**(`value?`): `any`

Gets or sets the height of the row in pixels.

**`example`**
```javascript
activeSheet.getRange(0, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).height(90);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `number` |

#### Returns

`any`

If no value is set, returns the row height; otherwise, returns the row.

___

### <a id="hidden" name="hidden"></a> hidden

▸ **hidden**(`value?`): `any`

Gets or sets whether the cell formula is visible.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).hidden(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell formula is hidden; otherwise, returns the cell.

___

### <a id="imemode" name="imemode"></a> imeMode

▸ **imeMode**(`value?`): `any`

Gets or sets the imeMode of the cell.

**`deprecated`** This property currently only works in Internet Explorer.

**`example`**
```javascript
activeSheet.getCell(0, 0).imeMode(GC.Spread.Sheets.ImeMode.disabled);
//or
var style = new GC.Spread.Sheets.Style();
style.imeMode = GC.Spread.Sheets.ImeMode.disabled;
activeSheet.setStyle(0, 0, style);
```

**`example`**
```javascript
activeSheet.getRange(2, -1, 1, -1).imeMode(GC.Spread.Sheets.ImeMode.active);
```

**`example`**
```javascript
activeSheet.getRange(-1, 2, -1, 1).imeMode(GC.Spread.Sheets.ImeMode.auto);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`ImeMode`](../enums/GC.Spread.Sheets.ImeMode) |

#### Returns

`any`

If no value is set, returns the cell imeMode; otherwise, returns the cell.

___

### <a id="isverticaltext" name="isverticaltext"></a> isVerticalText

▸ **isVerticalText**(`value?`): `any`

Gets or sets whether the cell's text is vertical.

**`example`**
```javascript
activeSheet.getRange(2,-1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).isVerticalText(false);
activeSheet.setText(2,0,"This is a test");
```

**`example`**
```javascript
activeSheet.getCell(1,1).isVerticalText(true);
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).isVerticalText(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell's text vertical; otherwise, returns the cell.

___

### <a id="labeloptions" name="labeloptions"></a> labelOptions

▸ **labelOptions**(`value?`): `any`

Gets or sets the cell label options.

**`example`**
```javascript
//This example sets label options for the watermark.
var type = new GC.Spread.Sheets.Style();
type.watermark = "User name";
type.cellPadding = "20";
type.labelOptions = {alignment:GC.Spread.Sheets.LabelAlignment.topLeft, visibility: GC.Spread.Sheets.LabelVisibility.visible};
activeSheet.setStyle(0, 1, type);
activeSheet.getRange(0, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).height(60);
activeSheet.getRange(-1, 1, -1, 1).width(150);
var combo = new GC.Spread.Sheets.CellTypes.ComboBox();
combo.items([{ text: "Oranges", value: "11k" }, { text: "Apples", value: "15k" }, { text: "Grape", value: "100k" }]);
combo.editorValueType(GC.Spread.Sheets.CellTypes.EditorValueType.text);
activeSheet.setCellType(2, 1, combo, GC.Spread.Sheets.SheetArea.viewport);
activeSheet.getCell(2, 1, GC.Spread.Sheets.SheetArea.viewport).watermark("ComboBox Cell Type").cellPadding('10 10 20 10');
activeSheet.getCell(2, 1, GC.Spread.Sheets.SheetArea.viewport).labelOptions({alignment: GC.Spread.Sheets.LabelAlignment.bottomCenter, foreColor: 'yellowgreen', font: 'bold 15px Arial'});
activeSheet.getRange(2, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).height(60);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`ILabelOptions`](../interfaces/GC.Spread.Sheets.ILabelOptions) |

#### Returns

`any`

If no value is set, returns the value of the cell label options; otherwise, returns the cell.

___

### <a id="locked" name="locked"></a> locked

▸ **locked**(`value?`): `any`

Gets or sets whether the cell is locked. When the sheet is protected, the locked cell cannot be edited.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).locked(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell is locked; otherwise, returns the cell.

___

### <a id="mask" name="mask"></a> mask

▸ **mask**(`value?`): `any`

Gets or sets the cell mask.

**`example`**
```javascript
//This example sets mask of the cell.
var style = new GC.Spread.Sheets.Style();
var pattern = "[a0_]{8}";
style.pattern = pattern;
activeSheet.setStyle(0, 1, style);
activeSheet.getCell(0, 1, GC.Spread.Sheets.SheetArea.viewport).mask({ pattern: pattern});
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`IMaskType`](../interfaces/GC.Spread.Sheets.IMaskType) |

#### Returns

`any`

If no value is set, returns the value of the cell mask; otherwise, returns the cell.

___

### <a id="quoteprefix" name="quoteprefix"></a> quotePrefix

▸ **quotePrefix**(`value?`): `any`

Gets or sets the quote prefix of the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).quotePrefix(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns the content of the quotePrefix; otherwise, returns the cell.

___

### <a id="resizable" name="resizable"></a> resizable

▸ **resizable**(`value?`): `any`

Gets or sets whether the row or column can be resized by the user.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1. GC.Spread.Sheets.SheetArea.viewport).resizable(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the user can resize the row; otherwise, returns the row or column.

___

### <a id="setborder" name="setborder"></a> setBorder

▸ **setBorder**(`border`, `option`): `void`

Sets the border for the specified area.

**`example`**
```javascript
//This example creates borders.
sheet.getCell(1, 1).borderTop(new GC.Spread.Sheets.LineBorder("#F0F8FF",GC.Spread.Sheets.LineStyle.double));
sheet.getCell(1, 1).borderLeft(new GC.Spread.Sheets.LineBorder("#F0F8FF",GC.Spread.Sheets.LineStyle.hair));
sheet.getCell(1, 1).borderRight(new GC.Spread.Sheets.LineBorder("#FAEBD7",GC.Spread.Sheets.LineStyle.dashDot));
sheet.getCell(1, 1).borderBottom(new GC.Spread.Sheets.LineBorder("#00FFFF",GC.Spread.Sheets.LineStyle.medium));
sheet.getRange(-1, 5, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderTop(new GC.Spread.Sheets.LineBorder("#F0FFFF",GC.Spread.Sheets.LineStyle.medium));
sheet.getRange(-1, 5, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderLeft(new GC.Spread.Sheets.LineBorder("#F5F5DC",GC.Spread.Sheets.LineStyle.medium));
sheet.getRange(-1, 5, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderRight(new GC.Spread.Sheets.LineBorder("#FF02FF", GC.Spread.Sheets.LineStyle.dashDot));
sheet.getRange(-1, 5, -1, 1, GC.Spread.Sheets.SheetArea.viewport).borderBottom (new GC.Spread.Sheets.LineBorder("#FFE4C4",GC.Spread.Sheets.LineStyle.thin));
sheet.getRange(2, 2, 2, 2, GC.Spread.Sheets.SheetArea.viewport).setBorder(new GC.Spread.Sheets.LineBorder("#8A2BE2",GC.Spread.Sheets.LineStyle.thick), { all:true });
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderTop( new GC.Spread.Sheets.LineBorder("#A52A2A",GC.Spread.Sheets.LineStyle.mediumDashed));
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderLeft( new GC.Spread.Sheets.LineBorder("#FF02FF",GC.Spread.Sheets.LineStyle.medium));
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderRight(new GC.Spread.Sheets.LineBorder("#5F9EA0", GC.Spread.Sheets.LineStyle.dashDot));
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).borderBottom(new GC.Spread.Sheets.LineBorder("#6495ED",GC.Spread.Sheets.LineStyle.dotted));
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).diagonalUp(new GC.Spread.Sheets.LineBorder("#FF02FF",GC.Spread.Sheets.LineStyle.dotted));
sheet.getRange(5, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).diagonalDown(new GC.Spread.Sheets.LineBorder("#6495ED",GC.Spread.Sheets.LineStyle.medium));
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `border` | [`LineBorder`](GC.Spread.Sheets.LineBorder) | The border line. |
| `option` | [`ISetBorderOptions`](../interfaces/GC.Spread.Sheets.ISetBorderOptions) | Determines which part of the cell range to set, the option object contains {all:true, left:true, top:true, right:true, bottom:true, diagonalUp:true, diagonalDown:true, outline:true,inside:true, innerHorizontal:true, innerVertical:true} |

#### Returns

`void`

___

### <a id="setstyle" name="setstyle"></a> setStyle

▸ **setStyle**(`value`): `void`

Sets the style for the cell.

**`example`**
```javascript
let style = new GC.Spread.Sheets.Style();
style.formatter = "#,##0.00";
sheet.getRange("E5:F10").setStyle(style);
sheet.getRange(0,0,4,4).setStyle(style);
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `value` | [`Style`](GC.Spread.Sheets.Style) | The style. |

#### Returns

`void`

___

### <a id="setstylename" name="setstylename"></a> setStyleName

▸ **setStyleName**(`value`): `void`

Sets the style name for the cell.

**`example`**
```javascript
let style = new GC.Spread.Sheets.Style();
style.name = "bold_style";
style.font = "bold 12px sans-serif";
sheet.addNamedStyle(style);
sheet.getRange("A1:D3").setStyleName("bold_style");
sheet.getRange(5,5,10,10).setStyleName("bold_style");
```

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `value` | `string` | The style name. |

#### Returns

`void`

___

### <a id="showellipsis" name="showellipsis"></a> showEllipsis

▸ **showEllipsis**(`value?`): `any`

Gets or sets the cell ellipsis property.

**`example`**
```javascript
activeSheet.getRange(2,-1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).showEllipsis(false);
activeSheet.setText(2,0,"This is a test");
```

**`example`**
```javascript
activeSheet.getCell(1,1).showEllipsis(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell ellipsis property.

___

### <a id="shrinktofit" name="shrinktofit"></a> shrinkToFit

▸ **shrinkToFit**(`value?`): `any`

Gets or sets whether the cell shrinks the text to fit the cell size.

**`example`**
```javascript
activeSheet.getRange(2,-1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).shrinkToFit(false);
activeSheet.setText(2,0,"This is a test");
```

**`example`**
```javascript
activeSheet.getCell(1,1).shrinkToFit(true);
```

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).shrinkToFit(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell shrinks the text to fit; otherwise, returns the cell.

___

### <a id="tabstop" name="tabstop"></a> tabStop

▸ **tabStop**(`value?`): `any`

Gets or sets a value that indicates whether the user can set focus to the cell using the Tab key.

**`example`**
```javascript
activeSheet.getCell(1,1).tabStop(false);
activeSheet.getRange(1, -1, 1, -1, GC.Spread.Sheets.SheetArea.viewport).tabStop(false);
activeSheet.getRange(-1, 1, -1, 1, GC.Spread.Sheets.SheetArea.viewport).tabStop(false);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the user can set focus to the cell using the Tab key; otherwise, returns the cell.

___

### <a id="tag" name="tag"></a> tag

▸ **tag**(`value?`): `any`

Gets or sets the tag for the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).tag("cell tag");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `any` |

#### Returns

`any`

If no value is set, returns the tag value; otherwise, returns the cell.

___

### <a id="text" name="text"></a> text

▸ **text**(`value?`): `any`

Gets or sets the formatted text for the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).text("cell object");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell text; otherwise, returns the cell.

___

### <a id="textdecoration" name="textdecoration"></a> textDecoration

▸ **textDecoration**(`value?`): `any`

Gets or sets the type of the decoration added to the cell's text.

**`example`**
```javascript
activeSheet.getRange(1, -1, 1, -1).textDecoration(GC.Spread.Sheets.TextDecorationType.overline | GC.Spread.Sheets.TextDecorationType.underline);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`TextDecorationType`](../enums/GC.Spread.Sheets.TextDecorationType) |

#### Returns

`any`

If no value is set, returns the type of the decoration; otherwise, returns the cell.

___

### <a id="textdirection" name="textdirection"></a> textDirection

▸ **textDirection**(`value?`): `any`

Gets or sets the type of the direction added to the cell's text.

**`example`**
```javascript
activeSheet.getRange(1, -1, 1, -1).textDirection(GC.Spread.Sheets.TextDirectionType.rightToLeft);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`TextDirectionType`](../enums/GC.Spread.Sheets.TextDirectionType) |

#### Returns

`any`

If no value is set, returns the type of the direction; otherwise, returns the cell.

___

### <a id="textindent" name="textindent"></a> textIndent

▸ **textIndent**(`value?`): `any`

Gets or sets the text indent of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).textIndent(1);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `number` |

#### Returns

`any`

If no value is set, returns the cell text indent; otherwise, returns the cell.

___

### <a id="textorientation" name="textorientation"></a> textOrientation

▸ **textOrientation**(`value?`): `any`

Gets or sets the text rotation angle of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).textOrientation(66);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `number` |

#### Returns

`any`

If no value is set, returns the cell text rotation angle; otherwise, returns the cell.

___

### <a id="themefont" name="themefont"></a> themeFont

▸ **themeFont**(`value?`): `any`

Gets or sets the theme font for the cell.

**`example`**
```javascript
activeSheet.getCell(-1, 0).themeFont("Body");
activeSheet.getCell(0,0).value("Test");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the cell's theme font; otherwise, returns the cell.

___

### <a id="tohtml" name="tohtml"></a> toHtml

▸ **toHtml**(`headerOptions?`, `includeStyle?`): `string`

Gets the HTML content from the specified area.

**`example`**
```javascript
activeSheet.getRange(0, 0, 10, 10).toHtml();
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `headerOptions?` | [`HeaderOptions`](../enums/GC.Spread.Sheets.HeaderOptions) |
| `includeStyle?` | `boolean` |

#### Returns

`string`

The HTML content that contains cell text, cell span and cell style.

___

### <a id="valign" name="valign"></a> vAlign

▸ **vAlign**(`value?`): `any`

Gets or sets the vertical alignment of the contents of the cell.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).vAlign(GC.Spread.Sheets.VerticalAlign.top);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`VerticalAlign`](../enums/GC.Spread.Sheets.VerticalAlign) |

#### Returns

`any`

If no value is set, returns the vertical alignment of the contents of the cell; otherwise, returns the cell.

___

### <a id="validator" name="validator"></a> validator

▸ **validator**(`value?`): `any`

Gets or sets the data validator for the cell.

**`example`**
```javascript
spread.options.highlightInvalidData = true;
var dv = GC.Spread.Sheets.DataValidation.createDateValidator(GC.Spread.Sheets.ConditionalFormatting.ComparisonOperators.between, new Date(2012, 11, 31), new Date(2013, 11, 31));
dv.showInputMessage(true);
dv.inputMessage("Enter a date between 12/31/2012 and 12/31/2013.");
dv.inputTitle("Tip");
activeSheet.getCell(0,0).validator(dv);
```

**`example`**
```javascript
spread.options.highlightInvalidData = true;
var dv = GC.Spread.Sheets.DataValidation.createDateValidator(GC.Spread.Sheets.ConditionalFormatting.ComparisonOperators.between, new Date(2012, 11, 31), new Date(2013, 11, 31));
dv.showInputMessage(true);
dv.inputMessage("Enter a date between 12/31/2012 and 12/31/2013.");
dv.inputTitle("Tip");
activeSheet.getCell(1, -1).validator(dv);
```

**`example`**
```javascript
spread.options.highlightInvalidData = true;
var dv = GC.Spread.Sheets.DataValidation.createListValidator("1,2,3");
dv.showInputMessage(true);
dv.inputMessage("Value must be 1,2 or 3");
dv.inputTitle("tip");
activeSheet.setDataValidator(-1,0,dv);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | [`DefaultDataValidator`](GC.Spread.Sheets.DataValidation.DefaultDataValidator) |

#### Returns

`any`

If no value is set, returns the cell data validator; otherwise, returns the cell.

___

### <a id="value" name="value"></a> value

▸ **value**(`value?`): `any`

Gets or sets the unformatted value of the cell.

**`example`**
```javascript
activeSheet.getCell(1,1).value(10);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `any` |

#### Returns

`any`

If no value is set, returns the cell value; otherwise, returns the cell.

___

### <a id="visible" name="visible"></a> visible

▸ **visible**(`value?`): `any`

Gets or sets whether the row or column is displayed.

**`example`**
```javascript
activeSheet.getCell(-1, 0).visible(false);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns the visible of the row or column; otherwise, returns the row or column.

___

### <a id="watermark" name="watermark"></a> watermark

▸ **watermark**(`value?`): `any`

Gets or sets the content of the cell watermark.

**`example`**
```javascript
activeSheet.getCell(1,1).watermark("lightgreen");
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `string` |

#### Returns

`any`

If no value is set, returns the content of the watermark; otherwise, returns the cell.

___

### <a id="width" name="width"></a> width

▸ **width**(`value?`): `any`

Gets or sets the width of the column in pixels.

**`example`**
```javascript
activeSheet.getCell(-1, 0).width(20);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `number` |

#### Returns

`any`

If no value is set, returns the column width; otherwise, returns the column.

___

### <a id="wordwrap" name="wordwrap"></a> wordWrap

▸ **wordWrap**(`value?`): `any`

Gets or sets whether the cell lets text wrap.

**`example`**
```javascript
activeSheet.getRange(-1, 3, -1, 1, GC.Spread.Sheets.SheetArea.viewport).wordWrap(true);
```

#### Parameters

| Name | Type |
| :------ | :------ |
| `value?` | `boolean` |

#### Returns

`any`

If no value is set, returns whether the cell lets text wrap; otherwise, returns the cell.
