Working with Date/Time Format Process

Navigation:  How to Work with Processes > Working with the Date Processes Group >

Working with Date/Time Format Process

Previous pageReturn to chapter overviewNext page

 

Process Purpose

 

The Date/Time Format process is used to convert a given date/time into a specific format. The result is stored in a variable.

Check the provided Date/Time Format examples at the end of the topic.

 

When you add a process, you are required to define its settings. This occurs in the process's properties window which is displayed automatically after having added the Date/Time Format process.

If any subsequent edition is required, double-click the process to open its properties window and enter the necessary modifications.

 

 

Proceed as follows:

 

Input

Format

Select an input format from the drop-down list or enter it with the use of a syntax list that is accessed by clicking . This format needs to match the format of the date/time value from the "Date" variable value. Ex: For a "Date" time presented like this: 09:50:25, use the following format: %H:%M:%S.

 

The "System Format" option is only available to define a "Date" format.

Date

Enter the input value of the date or time that will be formatted or click and select a variable with that value. See Variable Definition.

Result

Format

Select the output format for the result from the drop-down list or enter it with the use of a syntax list that is accessed by clicking .

 

The "System Format" option is only available to define a "Date" format.

Result Variable

Click to define the variable that will receive the result value. See To Select/Create a Variable.

 

If required, use the icon on the upper right corner of the properties window:

 

Use the icon to attach any relevant notes to this process. Click it and enter your notes in the resulting text box. These notes will be displayed in the corresponding "Actions" tab or "Process" window (in the "Notes" field) and in the "Developer Report".

 

After filling in the required options, click to conclude or to abort the operation.

 

The added process is displayed in the corresponding "Actions" tab or "Process" window.

 

 

If the source value for the date format is invalid (ex: b9F00) or left blank, the date format will display "99/99/9999".

 

 

 

Use the right click in MCL-Designer's input boxes to access certain features regarding the input box's option as well as general actions such as "Copy"; "Paste"; "Search".

Ex: If you right-click the "Variable" input box (included in a "Conversion's" properties window), you are provided with the "Search..."and "Variable Select" options.

If you right-click another input box, it will provide other possibilities.

 

 

 

Date/Time Format Examples

 

Example 1 - Input format = Date and Time (DD/MM/YYYY HH:MM:SS) >> output format = Date (YYYY/MM/DD)

 

Example 2 - Input format = Date and Time (YYYYMMDDHHMMSS) >> output format = Date (YY/MM/DD)

 

Example 3 - Input format = Date (YYYY-MM-DD) and Time  (HH:MM:SS) >> output format = Date (D/M/YY HH:MM:SS.MS)

 

Example 4 - Input format = Date (DD/M/YY) >> output format = Date (DD/MM/YYYY)