---
id: "T:cAlgo.API.FramesAddedEventArgs"
kind: "class"
namespace: "cAlgo.API"
url: "https://help.ctrader.com/ctrader-algo/references/EventArgs/FramesAddedEventArgs/"
---

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

# FramesAddedEventArgs (class)

Provides data for the frames added event.

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.

## Definition

```csharp
public class FramesAddedEventArgs
```

## Examples

C#:

```csharp
protected override void OnStart()
{
    ChartManager.FramesAdded += OnFramesAdded;
}

private void OnFramesAdded(FramesAddedEventArgs args)
{
    Print("{0} frame(s) added, total frames: {1}", args.AddedFrames.Length, ChartManager.Count);
}
```

Python:

```python
def on_start(self):
    api.ChartManager.FramesAdded += self.on_frames_added

def on_frames_added(self, args):
    api.Print(f"{len(args.AddedFrames)} frame(s) added, total frames: {api.ChartManager.Count}")
```

## Properties

- `public Frame[] AddedFrames {get;}` — Returns the added frames. [details](https://help.ctrader.com/ctrader-algo/references/EventArgs/FramesAddedEventArgs/AddedFrames/index.md)

