clsUTCToUserTimeZone Step

Use this step to convert UTC datetime to User's time zone.

Last published at: June 11th, 2024

Description:

This step converts UTC date time to the user's time zone.

 

Inputs

  • user - Provide User Id
  • utcVarGlobals - Select UTC date/time and variables/globals
 

 

Returns

  • True – step executed successfully 
  • False – step failed to execute
 

 

Usage:

 

 

Example:

Let’s build and execute the clsUTCToUserTimeZoneDef example.

  • Create a new definition called “clsUTCToUserTimeZoneDef
  • Select the definition and click the “design” button
  • Drag the above controls to the canvas
  • Connect the dots between the controls as above
  • Define a variable/global to store the result after execution
  • Click on the “clsUTCToUserTimeZone” step to configure its “Settings” properties. Provide a step name. Click on the button to provide a single User ID. Click the button to provide multiple variable/global UTC date-time values 

 

  • Click on the button to provide a single User ID. A popup window is displayed for configuration. Search for the user by the first 3 letters of the name. Use the navigation keys to select/unselect from the right-side list. You may also use a variable reference with a User's GUID ID value. Click the Save button to confirm. 

 

  • For example, the above-selected User has the EEST time zone. You must navigate the Administration—User Management page and search for the user. Double-click the row item to view the information below.  

 

  • Click on the button to provide UTC date-time value. A popup window is displayed for configuration. Provide the UTC date and time in the format below. This date-time value is converted to the user's time zone and stored in the variable/global reference. 

 

  • The “Logging” setting configuration is necessary for documentation and also measures the workflow progress and the percent complete. This is achieved by configuring the step state and percent fields individually, as shown in the images below. Configure the “Logging” using the following properties.

 

  • Save the process definition, create a new process instance, and execute. Render the process instance. Click on the process step to view its properties. The step should convert the UTC date-time value to match the User's time zone.  In the example, the UTC date-time value “2024-06-11T17:05:00” is converted to “2024-06-11T20:05:00” in the EEST time zone.