# Template screen item object

The following objects are directly related to the `templatescreenitem`
API.

### Template screen item

The template screen item object defines an element displayed on a
template screen. It has the following properties.

|Property|Type|Description|
|--------|----|-----------|
|screenitemid|string|*(readonly)* ID of the template screen item.|
|**resourceid**<br>(required)|string|ID of the object from the parent template displayed on the template screen item. Depending on the type of screen item, the `resourceid` property can reference different objects. Unused by clock and URL template screen items.<br><br>*Note: the `resourceid` property always references an object used in the parent template object, even if the screen item itself is inherited on a host or template.*|
|**resourcetype**<br>(required)|integer|Type of template screen item.<br><br>Possible values:<br>0 - graph;<br>1 - simple graph;<br>3 - plain text;<br>7 - clock;<br>11 - URL;<br>19 - simple graph prototype;<br>20 - graph prototype.|
|**screenid**<br>(required)|string|ID of the template screen that the item belongs to.|
|colspan|integer|Number of columns the template screen item will span across.<br><br>Default: 1.|
|elements|integer|Number of lines to display on the template screen item.<br><br>Default: 25.|
|halign|integer|Specifies how the template screen item must be aligned horizontally in the cell.<br><br>Possible values:<br>0 - *(default)* center;<br>1 - left;<br>2 - right.|
|height|integer|Height of the template screen item in pixels.<br><br>Default: 200.|
|max\_columns|integer|Specifies the maximum amount of columns a graph prototype or simple graph prototype screen element can have.<br><br>Default: 3.|
|rowspan|integer|Number or rows the template screen item will span across.<br><br>Default: 1.|
|style|integer|Template screen item display option.<br><br>Possible values for clock screen items:<br>0 - *(default)* local time;<br>1 - server time;<br>2 - host time.<br><br>Possible values for plain text screen items:<br>0 - *(default)* display values as plain text;<br>1 - display values as HTML.|
|url|string|URL of the webpage to be displayed in the template screen item. Used by URL template screen items.|
|valign|integer|Specifies how the template screen item must be aligned vertically in the cell.<br><br>Possible values:<br>0 - *(default)* middle;<br>1 - top;<br>2 - bottom.|
|width|integer|Width of the template screen item in pixels.<br><br>Default: 320.|
|x|integer|X-coordinates of the template screen item on the screen, from left to right.<br><br>Default: 0.|
|y|integer|Y-coordinates of the template screen item on the screen, from top to bottom.<br><br>Default: 0.|
