Date Time

Date Time

Activities


 


Create Date Time object

This activity creates a DateTime object based on the provided input data (year, month, day, hours, minutes, seconds, milliseconds).

Activity Parameters

The Create Date Time Object activity parameters can be provided by manual inserted values or via IN arguments or variables:

Parameters:

  • Days (text box editor type) (type: string): enter a valid day. For example, 9 (a date with the Day set on 9 will be created).
  • Hours (text box editor type) (type: string): enter hours. For example, 10 (a date with the Hour set on 10 will be created).
  • Milliseconds (text box editor type) (type: string): enter milliseconds. For example, 1 (a date with the Milliseconds set on 1 will be created).
  • Minutes (text box editor type) (type: string): enter minutes. For example, 10 (a date with the Minutes set on 10 will be created).
  • Months (text box editor type) (type: string): enter a valid month. For example, 3 (a date with the Month set on 3 will be created).
  • Seconds (text box editor type) (type: string): enter seconds. For example, 50 (a date with the Seconds set on 50 will be created).
  • Year (text box editor type) (type: string): enter a valid year. For example, 2016 (a date with the Year set on 2016 will be created).

The Read Only Output variable are the possible output values that the activity will provide:

  • DateTime Object (type: DateTime): outputs the DateTime Object according to the local settings.
 


Execution: the activity will create a Date Time object with the given values:









Current Date Time

This activity returns the current DateTime.

Activity Parameters

The Current Date Time activity parameters can be provided by manual inserted values or via IN arguments or variables:

The Read Only Output variable are the possible output values that the activity will provide:

  • DateTime Object (type: DateTime): outputs the DateTime Object according to the local settings.
 


Execution: the activity will get and output the current date and time:







Date to String Format

This activity takes the input DateTime Object and converts it to a String Format.

Activity Parameters

The Date to String Format activity parameters can be provided by manual inserted values or via IN arguments or variables:

Parameters:

  • Date Object (text box editor type) (type: DateTime): the DateTime Object. This parameter can be bound to the Out.put of a Create Date activity or to the Output of the Current Date Time activity (as seen in our example).
  • Date String Format (text box editor type) (type: string): Specify the format string that defines the text representation of the DateTime required as ''the date format for Output. For example, "dd.MM.yyyy"

The Read Only Output variable are the possible output values that the activity will provide:

  • Output String (type: string): outputs the DateTime Object as String, according to the Date String Format parameter.
 


Execution: the activity will convert the provided Date Time object into a string:




Date Time Span

This activity returns the interval between 2 DateTime objects.

Activity Parameters

The Date Time Span activity parameters can be provided by manual inserted values or via IN arguments or variables:

Parameters:

  • Input Start Date (text box editor type) (type: DateTime): the Input Start Date (DateTime object) or bind this parameter with the Output parameter of Create DateTime or Current Date Time activities.
  • Input End Date (text box editor type) (type: DateTime): the Input End Date (DateTime object) or bind this parameter with the Output parameter of Create DateTime or Current Date Time activities.

As mentioned above, the values for all the required parameters can be provided by IN arguments or variables. Below is an example of predefined arguments, ready to be used by the Date Time Span activity:

The Read Only Output variable are the possible output values that the activity will provide:

  • Days (type: string): outputs the interval of days between two DateTime Objects.
  • Hours (type: string): outputs the interval of hours between two DateTime Objects.
  • Milliseconds (type: string): outputs the interval of milliseconds between two DateTime Objects.
  • Minutes (type: string): outputs the interval of minutes between two DateTime Objects.
  • Seconds (type: string): outputs the interval of seconds between two DateTime Objects.
  • TimeSpan Object (type: TimeSpan): outputs the TimeSpan Object.
 


Execution: the activity will compare the given input dates and will output the difference between them:









Edit Date Time Object

This activity edits a DateTime Object (year, month, day, hours, minutes, seconds, milliseconds).

Activity Parameters

The Edit Date Time Object activity parameters can be provided by manual inserted values or via IN arguments or variables:

Parameters:

  • Days (text box editor type) (type: string): the number you want the days to be modified with. For example, if your current day is 7 and you want 8, just enter 1.
  • Hours (text box editor type) (type: string): the number you want the hours to be modified with. For example, if your current hours number is 7 and you want 8, just enter 1.
  • Input Date (text box editor type) (type: DateTime): the DateTime Object or bind this parameter with the Output parameter of a Date activity (Current Date Time or Create Date).
  • Milliseconds (text box editor type) (type: string): the number you want the milliseconds to be modified with. For example, if your current milliseconds number is 50 and you want 51, just enter 1.
  • Minutes (text box editor type) (type: string): the number you want the minutes to be modified with. For example, if your current minutes number is 50 and you want 51, just enter 1.
  • Months (text box editor type) (type: string): the number you want the month to be modified with. For example, if your current month is 7 and you want 8, just enter 1.
  • Seconds (text box editor type) (type: string): the number you want the seconds to be modified with. For example, if your current seconds number is 50 and you want 51, just enter 1.
  • Year (text box editor type) (type: string): the number you want the year to be modified with. For example, if your current year is 2016 and you want 2017, just enter 1.

The Read Only Output variable are the possible output values that the activity will provide:

  • DateTime Object (type: DateTime): outputs a DateTime Object.
 


Execution: the activity will take the given Input Date and will modify it by adding the new provided values (Days, Hours, Minutes etc). Below there can be seen a list with how the Edit Date Time Object activity is modifying the initial value:

  • if initial Days was set to 10 and the Edit Date Time Object's Days field is set to 2: the new date will have the Days set on 12
  • if initial Hours was set to 10 and the Edit Date Time Object's Hours field is set to 4: the new date will have the Hours set on 14 or 2 (if AM/PM is used)
  • if initial Milliseconds was set to 1 and the Edit Date Time Object's Milliseconds field is set to 5: the new date will have the Milliseconds set on 6
  • if initial Minutes was set to 10 and the Edit Date Time Object's Minutes field is set to 5: the new date will have the Minutes set on 15
  • if initial Months was set to 3 and the Edit Date Time Object's Months field is set to 1: the new date will have the Months set on 4
  • if initial Seconds was set to 50 and the Edit Date Time Object's Seconds field is set to 5: the new date will have the Seconds set on 55
  • if initial Year was set to 2016 and the Edit Date Time Object's Year field is set to 1: the new date will have the Year set on 2017











String to Date Object

This activity takes the input string date and reformat it to the local system format as DateTime Object.

Activity Parameters

The String to Date Object activity parameters can be provided by manual inserted values or via IN arguments or variables:

Parameters:

  • Input String (text box editor type) (type: string): the Date Time in a String format. This field can be bound to the output of an Date To String Format activity, for example.
  • Date String Format (text box editor type) (type: string): the format string of the date time string which was given in the Input String field. For example, if the date time string is "10.03.2016", then the Date String Format field should be "dd.MM.yyyy".

The Read Only Output variable are the possible output values that the activity will provide:

  • Date Object (type: DateTime): outputs the DateTime Object.
 


Execution: the activity will take the input date time string, will analyze its format and will convert the string into a Date Time Object, with the format of the machine's current date. The screen below illustrates how the input string looks (from DateToStringFormat activity) and how the obtained DateTimeObject looks (dateFormat activity):