---
id: "E:cAlgo.API.FavoriteTimeFrames.Removed"
kind: "event"
type: "T:cAlgo.API.FavoriteTimeFrames"
url: "https://help.ctrader.com/ctrader-algo/references/Plugin/TimeFrame/FavoriteTimeFrames/Removed/"
---

> Documentation index for agents: https://help.ctrader.com/ctrader-algo/llms.txt · machine index: https://help.ctrader.com/ctrader-algo/api.json

# FavoriteTimeFrames.Removed

Member of [FavoriteTimeFrames](https://help.ctrader.com/ctrader-algo/references/Plugin/TimeFrame/FavoriteTimeFrames/index.md).

## Removed

Occurs when TimeFrames are removed from favorite TimeFrames.

Environments: Desktop supported · CLI not supported · Cloud not supported.

- CLI: Available to plugins only, and plugins cannot run in the CLI.
- Cloud: Available to plugins only, and plugins cannot run in the cloud.

C#:

```csharp
event Action<FavoriteTimeFramesRemovedEventArgs> Removed;
```

Python:

```python
favoriteTimeFrames.Removed += handler  # handler(obj: FavoriteTimeFramesRemovedEventArgs)
```

### Returns

`Action<FavoriteTimeFramesRemovedEventArgs>` — 

Available since cAlgo.API 5.3.

### Examples

C#:

```csharp
protected override void OnStart()
{
    TimeFrameManager.Favorite.Removed += OnFavoriteTimeFramesRemoved;
}

private void OnFavoriteTimeFramesRemoved(FavoriteTimeFramesRemovedEventArgs args)
{
    foreach (var timeFrame in args.TimeFrames)
        Print("Removed from favorites: {0}", timeFrame.Name);
}
```

Python:

```python
def on_start(self):
    api.TimeFrameManager.Favorite.Removed += self.on_favorite_time_frames_removed

def on_favorite_time_frames_removed(self, args):
    for timeFrame in args.TimeFrames:
        api.Print(f"Removed from favorites: {timeFrame.Name}")
```

