<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [bitburner](./bitburner.md) &gt; [NS](./bitburner.ns.md) &gt; [clear](./bitburner.ns.clear.md)

## NS.clear() method

Clear data from a file.

**Signature:**

```typescript
clear(handle: string): void;
```

## Parameters

<table><thead><tr><th>

Parameter


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

handle


</td><td>

string


</td><td>

Text file to clear.


</td></tr>
</tbody></table>

**Returns:**

void

## Remarks

RAM cost: 0 GB

Delete all data from that text file.

