# rect.cell(i, j)

{% tabs %}
{% tab title="💾 程式" %}
```javascript
  // 🔸 rect.cell(i, j)
  cell(i, j){
    let row = this.row + i - 1;
    let col = this.col + j - 1;
    if (row < 0) throw new Error(`⛔ RangeRect.cell(): new rect can't start from row = ${row}`);
    if (col < 0) throw new Error(`⛔ RangeRect.cell(): new rect can't start from col = ${col}`);
    return new RangeRect(row, col, 1, 1);
  }
```
{% endtab %}

{% tab title="📘 手冊" %}
* [range](../../classes/range "mention") ⟩
  * [getCell(row, column)](https://developers.google.com/apps-script/reference/spreadsheet/range#getcellrow,-column) - cell (range) relative to range.
{% endtab %}
{% endtabs %}
