---
Product: Aspose.PDF
Platform: net
Page Type: reference
Canonical URL: https://reference.aspose.org/pdf/net/Cells
---

# Cells

## Overview

`Cells` is a class in Aspose.PDF FOSS for .NET.
Inherits from: `IEnumerable`.

A collection of cells in a row.

This class provides 12 methods for working with Cells objects in .NET programs.
Available methods include: `Add`, `At`, `Dispose`, `GetEnumerator`, `Insert`, `Remove`, `RemoveRange`.
All public members are accessible to any .NET application after installing the Aspose.PDF FOSS for .NET package.
Properties: `Count`.

## Properties

| Name | Type | Access | Description |
|------|------|--------|-------------|
| `Count` | `int` | Read | Number of cells. |

## Methods

| Signature | Description |
|-----------|-------------|
| `Add()` | Add a new empty cell and return it. |
| `Add(text: string)` | Add a cell with the specified text content. |
| `Add(text: string, ts: Text.TextState)` | Add a cell with the specified text content and pre-applied text state. |
| `Add(textFragment: Text.TextFragment)` | Add a cell containing a TextFragment. |
| `Add(cell: Cell)` | Add an existing cell. |
| `Insert(index: int, cell: Cell)` | Insert cell at the given zero-based index. |
| `Remove(cell: Cell)` | Remove cell if present. |
| `Remove(obj: object)` | Remove obj if it is a Cell that is present. |
| `RemoveRange(index: int, count: int)` | Remove count cells starting at index. |
| `Dispose()` | Releases per-cell resources. |
| `At(index: int)` | Get a cell by index. |
| `GetEnumerator()` | Calls GetEnumerator on this Cells instance. |

## See Also

- [Aspose.PDF for .NET — Enterprise API Reference](https://reference.aspose.com/pdf/net/)