---
name: "tvSetPicture"
type: command
status: ok
groups: ["GUI Control - Tree View"]
arma3_since: "0.74"
locality: {"argument": null, "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/tvSetPicture
revid: 378315
updated: 2026-04-02T16:16:24Z
---

# tvSetPicture

*Command · GUI Control - Tree View · Arma 3 v0.74*

## Description

Sets picture to item selected by path. IDC means id of parent Tree View. Name is picture name. The picture is searched in the mission directory.

> [!NOTE]
> - Adding pictures to lists is very slow. In order to prevent the filling of the list to be slowed down, add the pictures in a **scheduled** environment - See [#Example 3](../commands/tvSetPicture.md#example-3).
> One drawback of this method is that sorting the entries is not easily possible.
> - If not all items have a picture but you still want them to be aligned at the front, use a Procedural Texture that is transparent `1. (rgb,32,32,3)color(1,1,1,0)`.

## Syntax

### Syntax 1

```sqf
tvSetPicture [idc, path, name]
```

**Parameters:**

- `idc`: [Number](../topics/Number.md)
- `path`: [Tree View Path](../topics/Tree_View_Path.md)
- `name`: [String](../topics/String.md)

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

### Syntax 2

```sqf
control tvSetPicture [path, name]
```

**Parameters:**

- `control`: [Control](../topics/Control.md)
- `path`: [Tree View Path](../topics/Tree_View_Path.md)
- `name`: [String](../topics/String.md)

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

## Examples

### Example 1

```sqf
tvSetPicture [101, [0], "picture"];
```

### Example 2

```sqf
_ctrl tvSetPicture [[0,0,0], getText (configFile >> "CfgWeapons" >> "optic_NVS" >> "picture")];
```

### Example 3

Adding images in a scheduled environment:

```sqf
private _path = _ctrlTV tvAdd [[], "Some Entry"];
[_ctrlTV, _path] spawn {
    (_this select 0) tvSetPictureRight [[_this select 1], "someImage.paa"];
};
```

## See also

[tvPicture](../commands/tvPicture.md) · [tvSetPictureColor](../commands/tvSetPictureColor.md) · [tvSetPictureRight](../commands/tvSetPictureRight.md) · [tvSetPictureRightColor](../commands/tvSetPictureRightColor.md)

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