Default Year in Date field

P

Paul

How do I set-up a DD/MM/YY date field so that I can put a default value in
for the Year ?
 
T

Tim Ferguson

[email protected](Paul) wrote in
How do I set-up a DD/MM/YY date field so that I can put a default
value in for the Year ?

I'm afraid you are in the hands of Windows itself. If you type into any
standard control in Windows something like "25/12" it will be converted
into a date in the current year.

You will have to do some jiggery-pokery with the Text property but I have
a feeling that a control bound to a DateTime value will be coerced before
even the BeforeUpdate event has fired.

An alternative would be to pre-load the control with a suitable starting
date using the DefaultValue, so if it started out with 01/01/1999 the
user would only have to edit the first two parts.

Hope that helps


Tim F
 
Top