# .NET API Names

> Process workbooks in C# with ServerSheetControl: the Workbook, Worksheet, Cell and Range classes, Async methods and how Range differs from System.Range.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Topic
- **Path:** TX Sheet Control > Overview > .NET API Names
- **1811 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/overview/dotnet-api-names/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/overview/dotnet-api-names/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/overview/dotnet-api-names/llms-full.txt

---

The class names of the TX Sheet Control .NET API are short. The package name and the namespace already identify server processing, so the document API uses concise names such as `Workbook`, `Worksheet`, `TableCollection`, `Cell` and `Range`.

Read on for the processing entry point, the classes you use for document work, the naming of asynchronous methods and the difference between the spreadsheet `Range` and `System.Range`.

### How the Names Are Chosen

- **The entry point.** The .NET processing entry point is [ServerSheetControl](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontrol/llms-full.txt) in the namespace [TXTextControl.TXSheetControl.Server](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/llms-full.txt).
- **The `Async` suffix.** The `Async` suffix of a method name identifies an asynchronous operation. Await these operations.
- **No aliases.** There are no legacy API aliases.

### Process a Workbook

The following code writes two amounts and their sum into the first worksheet and saves the workbook as `invoice.pdf`:

```csharp
using TXTextControl.TXSheetControl.Server;

await using var control = new ServerSheetControl();
Workbook book = control.Workbook;
Worksheet sheet = await book.Sheets.AtAsync(0);
Cell amount = sheet.Cell("B8");
await amount.SetValueAsync(120);
await sheet.Cell("B9").SetValueAsync(80);
await sheet.Cell("B10").SetFormulaAsync("=SUM(B8:B9)");
await control.SaveAsync("invoice.pdf", StreamType.PDF);
```

The code works as follows:

- `new ServerSheetControl()` creates a control that owns an independent workbook. With `await using`, [DisposeAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontrol/disposeasync-method/llms-full.txt) releases the document and its resources at the end.
- [ServerSheetControl.Workbook](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontrol/workbook-property/llms-full.txt) returns the workbook. [Workbook.Sheets](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/workbook/sheets-property/llms-full.txt) and [SheetCollection.AtAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/sheetcollection/atasync-method/llms-full.txt) return the first worksheet, at index 0.
- [Worksheet.Cell](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/worksheet/cell-method/llms-full.txt) returns a handle for the cell at an A1 address of the worksheet.
- [Cell.SetValueAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/cell/setvalueasync-method/llms-full.txt) writes a literal value. [Cell.SetFormulaAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/cell/setformulaasync-method/llms-full.txt) writes a formula, which requires the leading equals sign.
- [ServerSheetControl.SaveAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontrol/saveasync-method/llms-full.txt) saves the workbook to a file, in the format the [StreamType](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/streamtype/llms-full.txt) value `PDF` selects.

### Which Classes You Work With

Use `Workbook`, `Worksheet`, `Cell`, `Range` and their owned collections for document work:

| Class | Purpose |
|---|---|
| [Workbook](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/workbook/llms-full.txt) | Asynchronous workbook editing, formatting, calculation, loading and saving |
| [Worksheet](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/worksheet/llms-full.txt) | A handle bound to a worksheet ID and an opaque document generation |
| [Cell](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/cell/llms-full.txt) | A worksheet-bound cell handle that separates literal text, formulas, values, formatting and pictures |
| [Range](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/range/llms-full.txt) | A worksheet-bound rectangular range for atomic reads, writes, formatting and copy operations |
| [TableCollection](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/tablecollection/llms-full.txt) | The Excel tables of a worksheet, with workbook-unique names and stable identities |
| [DocumentObject](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/documentobject/llms-full.txt) | The base for sheet-bound handles. Its methods perform asynchronous I/O; creating a cell or range handle performs none |

[ServerSheetControlOptions](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontroloptions/llms-full.txt), the document limits, locale and font settings for server spreadsheet operations, and [ServerSheetControlException](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/serversheetcontrolexception/llms-full.txt) describe the processing entry point.

### Distinguish Range From System.Range

The spreadsheet `Range` class and `System.Range` are different types. Prefer `var` when you obtain worksheet ranges, or add an alias when you declare the type explicitly:

```csharp
using Range = TXTextControl.TXSheetControl.Server.Range;
using TXTextControl.TXSheetControl.Server;

async Task SetAmountsAsync(Worksheet sheet)
{
    Range amounts = sheet.Range("B8:B9");
    await amounts.SetValuesAsync(new object?[][] { [120], [80] });
}
```

The code works as follows:

- The alias `using Range = TXTextControl.TXSheetControl.Server.Range;` makes `Range` name the spreadsheet class, not `System.Range`.
- [Worksheet.Range](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/worksheet/range-method/llms-full.txt) returns a handle for the range `B8:B9`.
- [Range.SetValuesAsync](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/txtextcontrol-txsheetcontrol-server/range/setvaluesasync-method/llms-full.txt) writes 120 into `B8` and 80 into `B9`.

### What the Reference Describes

All signatures, examples and routes of the reference describe the current TX Sheet Control packages. Earlier product namespaces, package names and reference routes are not supported.

### Next Steps

- [.NET](https://docs.textcontrol.com/tx-sheet-control/getting-started/document-processing/dotnet/llms-full.txt): install the Server package and process a first workbook in .NET.
- [Workbooks and Worksheets](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/workbooks/llms-full.txt): workbook ownership, worksheet handles and document replacement.
- [Tables](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/tables/llms-full.txt): Excel-style tables with named columns and calculated columns.
- [.NET API](https://docs.textcontrol.com/tx-sheet-control/reference/dotnet-api/llms-full.txt): the namespaces, classes and members of the .NET API.

---

## Nearby

- **Previous:** [Introduction](https://docs.textcontrol.com/tx-sheet-control/overview/introduction/llms-full.txt)
- **Next:** [Sample Documents](https://docs.textcontrol.com/tx-sheet-control/overview/sample-documents/llms-full.txt)
