[Overview][Constants][Procedures and functions] Reference for unit 'dateutils' (#rtl)

EncodeDateWeek

Encode a TDateTimevalue from a year, week and day of week triplet

Declaration

Source position: line 0

function EncodeDateWeek(

  const AYear: Word;

  const AWeekOfYear: Word;

  const ADayOfWeek: Word

):TDateTime;

function EncodeDateWeek(

  const AYear: Word;

  const AWeekOfYear: Word

):TDateTime;

Arguments

AYear

  

Year part

AWeekOfYear

  

Week of the year part

Function result

DateTime value representing AYear, AWeekOfYearand ADayOfWeek.

Arguments

AYear

  

Year part

AWeekOfYear

  

Week of the year part

Function result

DateTime value representing AYear, AWeekOfYearand ADayOfWeek.

Description

EncodeDateWeekencodes the values AYear, AWeekOfYearand ADayOfWeekto a date value and returns this value.

For an example, see DecodeDateWeek.

Errors

If any of the arguments is not valid, then an EConvertErrorexception is raised.

See also

EncodeDateMonthWeek

  

Encodes a year, month, week of month and day of week to a DateTime value

DecodeDateWeek

  

Decode a DateTime value in a week of year and day of week.

EncodeDateTime

  

Encodes a DateTime value from all its parts

EncodeDateDay

  

Encodes a year and day of year to a DateTime value

TryEncodeDateTime

  

Encode a Year, Month, Day, Hour, minute, seconds, milliseconds tuplet to a TDateTimevalue

TryEncodeDateWeek

  

Encode a year, week and day of week triplet to a TDateTimevalue

TryEncodeDateMonthWeek

  

Encode a year, month, week of month and day of week to a TDateTimevalue