# TextControl.ResetContents Method

> Deletes the entire contents of the control.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Method
- **Introduced:** 23.0
- **Namespace:** `TXTextControl.Web`
- **Assembly:** `TXTextControl.Web.dll`, which the TX Text Control .NET Server setup installs, for .NET Framework; in no NuGet package
- **Path:** TX Text Control .NET Server > Reference > TXTextControl.Web > TextControl.ResetContents Method
- **305 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-web/textcontrol/resetcontents-method/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-web/textcontrol/resetcontents-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-web/textcontrol/resetcontents-method/llms-full.txt

---

### Description

Deletes the entire contents of the control.

### Syntax

```csharp
public void ResetContents();
```

```vbnet
Public Sub ResetContents()
```

### Examples

`ResetContents` is not exposed by the current ASP.NET Core editor helper. The following example uses `LoadText` in the current server-side setup instead.

```csharp
var result = textControl.LoadText(@"App_Data\document.docx", TXTextControl.Web.StreamType.PlainAnsiText);
Console.WriteLine(result);
```

```vbnet
Dim result = textControl.LoadText("App_Data\document.docx", TXTextControl.Web.StreamType.PlainAnsiText)
Console.WriteLine(result)
```

---

## Nearby

- **Previous:** [TextControl.LoadXMLDatabaseAsync Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-web/textcontrol/loadxmldatabaseasync-method/llms-full.txt)
- **Next:** [TextControl.SaveDocumentQuestionDialogEnabled Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-web/textcontrol/savedocumentquestiondialogenabled-property/llms-full.txt)
