Convert date time with time zone to UTC
Let’s build and execute the clsDateTimeToUTCDef example.
- Create a new definition called “clsDateTimeToUTCDef”
- Select the definition and click the “design” button
- Drag the above controls to the canvas
- Connect the dots between the controls as above
- Click on the “UpdateVariables” step to configure its properties
- Click on the “Update multiple variables" option to define multiple date time values for conversion as shown in below graphic
- Click on the “clsDateTimeToUTC” step to configure its properties as shown on the below graphic
- Select the preferred time zone as reference for conversion or leave it unselected as it's optional
- The time zone value (when unselected) takes the reference from the FW database - deConfig table (shown below) and this can be configured with any global time zone name. This deConfig - ConfigKey is defined manually with v9.10.0.x patch releases. In this example, the ConfigKey is referring to FINNISH timezone. With FlowWright v9.12 (and later), the default time zone can be configured by navigating to Status - Status - Information - Culture page.
- In “clsDateTimeToUTC” step, Define multiple date time values and configure the variables as shown on the below graphic
- Save the process definition, create a process instance and execute.
- Check the step properties by rendering the workflow instance. clsDateTimeToUTC step should convert the provided date time (with time zone) to UTC as shown on the below graphic.