# EditDT

## `EditDT` (FB)

FUNCTION\_BLOCK EditDT

### Short description

> Input of a date and time in the DATE\_AND\_TIME format ( dt#2017-11-21-14:36:00 )\
> Typical application: setting a switching time

### Representation

<figure><img src="https://2592874069-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQR4vCFzt6ixgsqlR3pdR%2Fuploads%2Fgit-blob-0c147e77df5039b3a422b3fc147751311e6b3bb5%2Fimage%20(21).png?alt=media" alt=""><figcaption></figcaption></figure>

### Interfaces

#### Outputs

| Name    | Data type       | Value range | Initial value | Function                               |
| ------- | --------------- | ----------- | ------------- | -------------------------------------- |
| *dtOut* | DATE\_AND\_TIME |             |               | Output value in DATE\_AND\_TIME format |

#### Setpoints / parameters

| Name           | Data type       | Value range | Initial value | Function                              |
| -------------- | --------------- | ----------- | ------------- | ------------------------------------- |
| **dtSetPoint** | DATE\_AND\_TIME |             |               | Input value in DATE\_AND\_TIME format |

### Function description

#### General

This function block is used to pass an input value in DATE\_AND\_TIME format **dtSetPoint** and the direct transfer to the output value in DATE\_AND\_TIME format *dtOut*.\\

> **Behavior in case of power failure**
>
> The input value in DATE\_AND\_TIME format **dtSetPoint** is stored fail-safe and automatically restored.

### CODESYS

InOut:

| Scope       | Name         | Type |
| ----------- | ------------ | ---- |
| Input Const | `dtSetPoint` | `DT` |
| Output      | `dtOut`      | `DT` |
