---
id: "M:cAlgo.API.ChartDraggables.Add"
kind: "method"
type: "T:cAlgo.API.ChartDraggables"
url: "https://help.ctrader.com/ctrader-algo/references/Chart/Draggables/ChartDraggables/Add/"
---

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

# ChartDraggables.Add

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

## Add()

Adds a draggable to chart area.

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

- CLI: Add returns a draggable that is never displayed; Remove sends nothing to any chart.
- Cloud: Add returns a draggable that is never displayed; Remove sends nothing to any chart.

C#:

```csharp
ChartDraggable Add()
```

Python:

```python
chartDraggables.Add() -> ChartDraggable
```

### Returns

`ChartDraggable` — Draggable

Available since cAlgo.API 5.2.

### Examples

C#:

```csharp
var draggable = Chart.Draggables.Add();
draggable.Child = new TextBlock { Text = "Drag me", BackgroundColor = Color.Black };
Print("Draggables on the chart: {0}", Chart.Draggables.Count);
```

Python:

```python
draggable = api.Chart.Draggables.Add()
textBlock = TextBlock()
textBlock.Text = "Drag me"
draggable.Child = textBlock
api.Print(f"Draggables on the chart: {api.Chart.Draggables.Count}")
```

