[comment]: # translation:outdated

[comment]: # ({3322a856-3322a856})
# templatescreen.update

[comment]: # ({/3322a856-3322a856})

[comment]: # ({1e60acfc-1e60acfc})
### Description

`object templatescreen.update(object/array templateScreens)`

This method allows to update existing template screens.

[comment]: # ({/1e60acfc-1e60acfc})

[comment]: # ({3498b558-3498b558})
### Parameters

`(object/array)` Template screen properties to be updated.

The `screenid` property must be defined for each template screen, all
other properties are optional. Only the passed properties will be
updated, all others will remain unchanged.

Additionally to the [standard template screen
properties](object#template_screen), the method accepts the following
parameters.

|Parameter|[Type](/manual/api/reference_commentary#data_types)|Description|
|---------|---------------------------------------------------|-----------|
|screenitems|array|Template [screen items](/manual/api/reference/templatescreenitem/object) to replace existing screen items.<br><br>Screen items are updated by coordinates, so each screen item must have the `x` and `y` properties defined.|

[comment]: # ({/3498b558-3498b558})

[comment]: # ({4dc47ba2-4dc47ba2})
### Return values

`(object)` Returns an object containing the IDs of the updated template
screens under the `screenids` property.

[comment]: # ({/4dc47ba2-4dc47ba2})

[comment]: # ({b41637d2-b41637d2})
### Examples

[comment]: # ({/b41637d2-b41637d2})

[comment]: # ({5c75e0d1-5c75e0d1})
#### Rename a template screen

Rename the template screen to "Performance graphs".

Request:

``` {.java}
{
    "jsonrpc": "2.0",
    "method": "templatescreen.update",
    "params": {
        "screenid": "3",
        "name": "Performance graphs"
    },
    "auth": "038e1d7b1735c6a5436ee9eae095879e",
    "id": 1
}
```

Response:

``` {.java}
{
    "jsonrpc": "2.0",
    "result": {
        "screenids": [
            "3"
        ]
    },
    "id": 1
}
```

[comment]: # ({/5c75e0d1-5c75e0d1})

[comment]: # ({9c4d8c39-9c4d8c39})
### Source

CTemplateScreen::update() in
*ui/include/classes/api/services/CTemplateScreen.php*.

[comment]: # ({/9c4d8c39-9c4d8c39})
