DateTime

Parse DateTime

6min

This action parses a DateTime value from a String, based on a custom format specification.

Document image


Inputs & Outputs

  • [ I ] String: String value to parse from.
  • [ I ] Language: Language used in the Input string for month names and days of the week.
    • Drop-down with multiple languages.
  • [ I ] Format: String containing the DateTime format specification.
  • [ O ] Date: Parsed DateTime value.
Document image


Example Usage

  • Drag action onto the canvas to get familiarized with it.
Document image

  • Declare some variables to be used with the action.
Document image

  • Assign the newly created variables.
  • Save & Run the process and then Check Instance to see the output.
Document image


Use Cases

  • Extracting DateTime values from bodies of text coming from any source.
  • Translating month names or days of the week from one language to another using the Parse DateTime and Format DateTime actions together.

Tips

  • The Format field uses standard .NET format specifiers which are documented here.
  • The Language selector picks which language should be used when the wanted format contains :
    • Month names : June (UK) 🆚 Iunie (RO) 🆚 Juin (FR)
    • Days of the week : Monday (UK) 🆚 Luni (RO) 🆚 Lundi (FR)
    • Abbreviations
  • Make sure to escape letters used as format specifiers using quotes otherwise those letters will be treated as placeholders for DateTime fields and the action will fail when attempting to parse.