Date/Time routines
|
CompareDate functionCompares two TDateTime values (returns "less", "equal" or "greater"). Ignores the Time part if both values "fall" on the same day.
CompareDateTime functionCompares two TDateTime values (returns "less", "equal" or "greater").CompareTime functionCompares two TDateTime values (returns "less", "equal" or "greater"). Ignores the Date part if both values occur at the same time.Date functionReturns the current system date.DateToStr functionConverts a TDateTime value to a string (date part only).DateTimeToFileDate functionConverts a TDateTime value to a system timestamp value.DateTimeToStr functionConverts a TDateTime value to a string (date and time).DateOfWeek functionReturns the day of the week for a given date.DateOfTheWeek functionReturns the day of the week for a given TDateTimeValue.DayOfTheMonth functionReturns the day of the month from a given TDateTime value (from 1 to 31)DayOfTheYear functionReturns the the ordinal position of a TDateTime value's day within its year.DaySpan functionGives the number of days (including fractional days) between two specified dates.DaysBetween functionGives the number of whole days between two specified dates.DateOf functionReturns only the Date portion of the TDateTime value, by setting Time part to 0.DecodeDate functionSeparates Year, Month, and Day values from a TDateTime value.DecodeTime procedureSeparates Hour, Minute, Second, and MilliSecond values from a TDateTime value.EncodeDate functionCreates a TDateTime value from Year, Month, and Day values.EncodeTime functionCreates a TDateTime value from Hour, Min, Sec, and MSec. values.FormatDateTime functionFormats a TDateTime value to a string.HourOf functionReturns the hour of the day represented by a TDateTime value.IncDay functionAdds or substracts a given number of days from a date value.IncMonth functionAdds or substracts a given number of months from a date value.IsLeapYear functionReturns True if a year specified is a leap year.IsPM functionReturns true if the time portion of a TDateTime value occurs on or after 12:00 (noon) and before 24:00 (midnight).Now functionReturns the current system date and time.Time functionReturns the current system time.TimeToStr functionConverts a TDateTime value to a string (time part).TimeOf functionReturns only the Time portion of the TDateTime value, by setting Date part to 0.WithinPastDays functionReturns true if two dates are within a specified number of days of each other.WithinPastYears functionReturns true if two dates are within a specified number of years of each other.YearsBetween functionGives the number of whole years between two specified dates.more to come...
sumber:
http://delphi.about.com/od/beginners/l/blrtldatetime.htm
No comments:
Post a Comment