> For the complete documentation index, see [llms.txt](https://tariksavas.gitbook.io/tarsave/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tariksavas.gitbook.io/tarsave/docs/how-to-use/datapersistenceservice/delete.md).

# Delete

<pre class="language-csharp"><code class="lang-csharp"><strong>bool Delete(string key)
</strong></code></pre>

**Purpose:** Deletes a file corresponding to the specified key.&#x20;

**Parameters:**&#x20;

* key: A string that specifies the file path to be deleted.&#x20;

**Return Value:** Returns true if the file deletion was successful, false otherwise.

```csharp
public void Delete()
{
    bool result = _dataPersistenceService.Delete("Key");
}
```
