---
id: "M:cAlgo.API.DropZone.#ctor"
kind: "constructor"
type: "T:cAlgo.API.DropZone"
url: "https://help.ctrader.com/ctrader-algo/references/Controls/DropZone/Constructor/"
---

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

# DropZone constructor

Member of [DropZone](https://help.ctrader.com/ctrader-algo/references/Controls/DropZone/index.md).

## DropZone()

Initializes a new instance of the DropZone class.

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

- CLI: Accepted without error but never displayed, so control events such as Click are never raised.
- Cloud: Accepted without error but never displayed, so control events such as Click are never raised.

C#:

```csharp
public DropZone()
```

Python:

```python
DropZone()
```

Available since cAlgo.API 5.1.

### Examples

C#:

```csharp
var dropZone = new DropZone { Child = new TextBlock { Text = "Drop a CSV file here" } };
dropZone.Dropped += args => Print("Dropped {0} file(s)", args.FilePaths.Count);
Chart.AddControl(dropZone);
```

Python:

```python
dropZone = DropZone()
child = TextBlock()
child.Text = "Drop a CSV file here"
dropZone.Child = child
dropZone.Dropped += lambda args: api.Print(f"Dropped {args.FilePaths.Count} file(s)")
api.Chart.AddControl(dropZone)
```

