# Cancel()

> Cancels the awaitable. If the awaitable is being awaited, the awaiter receives a System.OperationCanceledException.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.0/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
public void Cancel()
```

### Remarks

**Note:** Some methods returning an `Awaitable` also accept a `CancellationToken`, such as [Awaitable.WaitForSecondsAsync](/engine/6000.0/script-reference/unityengine/awaitable/waitforsecondsasync.md) and [Awaitable.NextFrameAsync](/engine/6000.0/script-reference/unityengine/awaitable/nextframeasync.md). For such methods, both cancellation models are equivalent: whether you call `Awaitable.Cancel` directly or trigger the supplied `CancellationToken`, the awaiter receives an `OperationCanceledException`.
