---
id: "P:cAlgo.API.ChartManager.ActiveFrame"
kind: "property"
type: "T:cAlgo.API.ChartManager"
url: "https://help.ctrader.com/ctrader-algo/references/Plugin/Chart/ChartManager/ActiveFrame/"
---

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

# ChartManager.ActiveFrame

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

## ActiveFrame

Returns current active frame if any otherwise null.

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
Frame ActiveFrame {get;}
```

Python:

```python
api.ChartManager.ActiveFrame: Frame
```

### Returns

`Frame` — 

### Examples

C#:

```csharp
if (ChartManager.ActiveFrame is ChartFrame chartFrame)
    Print("Active chart: {0} {1}", chartFrame.Symbol.Name, chartFrame.TimeFrame);
```

Python:

```python
activeFrame = api.ChartManager.ActiveFrame
if activeFrame is not None and isinstance(activeFrame.__implementation__, ChartFrame):
    chartFrame = ChartFrame(activeFrame)
    api.Print(f"Active chart: {chartFrame.Symbol.Name} {chartFrame.TimeFrame}")
```

