---
name: "BIS_fnc_taskSetState"
type: function
status: ok
groups: ["Tasks"]
arma3_since: "1.00"
locality: {"argument": "global", "effect": "global", "server_exec": false}
source: https://community.bistudio.com/wiki/BIS_fnc_taskSetState
revid: 364616
updated: 2024-05-22T11:37:48Z
---

# BIS_fnc_taskSetState

*Function · Tasks · Arma 3 v1.00*

Locality: arguments **global** · effect **global**

## Description

Set a task's state. 

> [!NOTE]
> See Arma 3: Task Framework for more information.

## Syntax

```sqf
[taskName, taskState, showHint] call BIS_fnc_taskSetState
```

**Parameters:**

- `taskName`: [String](../topics/String.md)
- `taskState`: [String](../topics/String.md) - can be:
  - "CREATED"
  - "ASSIGNED"
  - "SUCCEEDED"
  - "FAILED"
  - "CANCELED"
- `showHint`: [Boolean](../topics/Boolean.md) - (Optional, default [true](../commands/true.md)) [true](../commands/true.md) to show a hint

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

## Examples

### Example 1

```sqf
["BIS_task_01","CANCELED"] call BIS_fnc_taskSetState;
```

## See also

Arma 3: Task Framework

## Community notes

**Whiztler** — 2024-05-22

Mind the spelling of the TaskState parameter string "CANCELED". The parameter will not work with the TaskState correctly spelled "CANCELLED".

<sub>Source: [BI Community Wiki — BIS fnc taskSetState](https://community.bistudio.com/wiki/BIS_fnc_taskSetState) (revision 364616).</sub>
