Previous Topic: GetDefaultYear Method—Implements a customer-specified algorithm addressing Year-2000 concernsNext Topic: Arguments


Purpose

GetDefaultYear () is invoked when input editing occurs on a date or timestamp field, and the edit pattern specifies a two character year value. The 4-digit current year and the 2-digit input year are passed to GetDefaultYear (). By default, the current hundred year value is merely added to the two character year value and returned. This method allows the implementation of a customer-specified algorithm addressing Year-2000 concerns.

The default algorithm returns the current hundred years appended with two digit input year. The private method ImputeCenturies() enables an alternative algorithm, implementing a sliding range of hundred year values based on the input decade.