---
name: "lbCurSel"
type: command
status: ok
groups: ["GUI Control - ListBox"]
arma3_since: "0.50"
locality: {"argument": null, "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/lbCurSel
revid: 379432
updated: 2026-10-31T00:05:45Z
---

# lbCurSel

*Command · GUI Control - ListBox · Arma 3 v0.50 · introduced in Operation Flashpoint v1.75*

## Description

Returns the index of the selected item of the [CT_LISTBOX](../topics/CT_LISTBOX.md), [CT_LISTNBOX](../topics/CT_LISTNBOX.md), [CT_COMBO](../topics/CT_COMBO.md) or [CT_TOOLBOX](../topics/CT_TOOLBOX.md). For [CT_LISTBOX](../topics/CT_LISTBOX.md) with multi selection enabled use [lbSelection](../commands/lbSelection.md).

## Syntax

### Syntax 1

```sqf
lbCurSel idc
```

**Parameters:**

- `idc`: [Number](../topics/Number.md)

**Returns:** [Number](../topics/Number.md) - selected index (row) or -1 if nothing is selected

### Syntax 2

```sqf
lbCurSel control
```

**Parameters:**

- `control`: [Control](../topics/Control.md)

**Returns:** [Number](../topics/Number.md) - selected index (row) or -1 if nothing is selected

## Examples

### Example 1

```sqf
_index = lbCurSel 101;
```

### Example 2

```sqf
lbCurSel _ctrl;
```

## See also

[lbIsSelected](../commands/lbIsSelected.md) · [lbSelection](../commands/lbSelection.md) · [lbSetCurSel](../commands/lbSetCurSel.md)

## Community notes

**ffur2007slx2_5** — 2014-09-10

More information on the [CT_LISTBOX](../topics/CT_LISTBOX.md) command family can be found [here](../topics/CT_LISTBOX.md#scripting-example).

<sub>Source: [BI Community Wiki — lbCurSel](https://community.bistudio.com/wiki/lbCurSel) (revision 379432).</sub>
