DateUtils.DecodeDateWeek

From RAD Studio VCL Reference
Jump to: navigation, search

Contents

Delphi Information

From DateUtils.pas

	procedure DecodeDateWeek(const AValue: TDateTime;
		out AYear: Word;
		out AWeekOfYear: Word;
		out ADayOfWeek: Word);


Unit: DateUtils

Type: procedure

Visibility: public

C++ Information

From DateUtils.hpp

	void __fastcall DecodeDateWeek(System::TDateTime AValue,
		unsigned short & AYear,
		unsigned short & AWeekOfYear,
		unsigned short & ADayOfWeek);


Unit: DateUtils

Type: function

Description

Returns the year, week of the year, and day of the week for a specified TDateTime value object.


DecodeDateWeek returns the day of the week and week of the year for a specified date/time value, along with the year in which that day and week occur.

AValue is the date/time value about which you want information.

AYear returns the year that AValue represents.

AWeekOfYear returns the week within AYear that AValue represents, where 1 is the first week with four or more days.

ADayOfWeek returns the day within AWeekOfYear that AValue represents, where 1 is Monday and 7 is Sunday.

Note:  The definitions for AWeekOfYear and ADayOfWeek follow the ISO 8601 standard.
Tip:  To make the ADayOfWeek value more readable, use the day of week constants.

See Also

Code Samples


Personal tools
Translations
Newest Version