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

# sliderSetPosition

*Command · GUI Control · Arma 3 v0.50 · introduced in Operation Flashpoint v1.85*

## Description

Sets current thumb position of [CT_SLIDER](../topics/CT_SLIDER.md) or [CT_XSLIDER](../topics/CT_XSLIDER.md).

## Syntax

### Syntax 1

```sqf
sliderSetPosition [idc, pos]
```

**Parameters:**

- `idc`: [Number](../topics/Number.md) - idc of the control
- `pos`: [Number](../topics/Number.md)

**Returns:** [Nothing](../topics/Nothing.md)

### Syntax 2

```sqf
control sliderSetPosition pos
```

**Parameters:**

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

**Returns:** [Nothing](../topics/Nothing.md)

## Examples

### Example 1

```sqf
_ctrlSlider sliderSetPosition 50;
```

## See also

[sliderPosition](../commands/sliderPosition.md) · [sliderRange](../commands/sliderRange.md) · [sliderSetRange](../commands/sliderSetRange.md) · [sliderSetSpeed](../commands/sliderSetSpeed.md) · [sliderSpeed](../commands/sliderSpeed.md) · [ctrlSetScrollValues](../commands/ctrlSetScrollValues.md) · [progressSetPosition](../commands/progressSetPosition.md)

## Community notes

**POLPOX** — 2020-01-22

[sliderSetPosition](../commands/sliderSetPosition.md) doesn't fire [onSliderPosChanged](../topics/User_Interface_Event_Handlers.md#onsliderposchanged) events.

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