Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

Adds specified number of hours to specified date time value and returns asynchronously.

Promise<DateTimeOffset> Calendar.AddAsync(dateTime: DateTimeOffset, hours: number)

Arguments

Specifies the base date time value.
number hours
Specifies the how many hours will be added to dateTime parameter.

Example

Code Block
languagejs
//adds 4 hours to the current date and returns the result as a DateTimeOffset object.
$Calendar.AddAsync($Calendar.Today, 4).then(function(newDate) {
console.log(newDate);
});

Examples

Code Block
languagejs
//adds 4 hours to the current date and returns the result as a DateTimeOffset object.
$Calendar.AddAsync($Calendar.Today, 4).then(function(newDate) {
console.log(newDate);
});