RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
DateUtils.StartOfTheYear Function

Returns a TDateTime that represents 12:00:00:00 AM on the first day of the year identified by a specified TDateTime.

Pascal
function StartOfTheYear(const AValue: TDateTime): TDateTime;
C++
TDateTime StartOfTheYear(const TDateTime AValue);

StartOfTheYear returns the first expressible moment of the same year as the TDateTime specified by AValue. That is, it replaces the time portion of AValue with 0, changes the day to January 1, and returns the result. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!