Wrox Home  
Search P2P Archive for: Go

  Return to Index  

access thread: invalid dates


Message #1 by jbird@a... on Tue, 18 Mar 2003 15:02:56 -0500

I have another problem that has been causing me a lot of headaches. I have some
date fields that are formatted a little different than normal. They are
yy/mm/dd.  I am using this Input Mask (00/00/00;0;_) to get the date in the
right format. My problem is Access allows such invalid dates as 83/55/66 to be
entered. I am not sure how to correct this. Any ideas?

Thanks in advance.

-Joe



Message #2 by "Rob Wills" <robertiwills@h...> on Wed, 19 Mar 2003 15:57:37
> Joe,
Is the data entry done through a form in Access?

if so then you could add data checking to the change event of the text box.

Alternatively there is an ActiveX calendar which you can force the users 
to select the date, then you can derive the date format using the Format 
function in VBA.

Hope this helps
Rob
Message #3 by "Vince Kingston" <valandria@t...> on Thu, 20 Mar 2003 16:03:34
> > Joe,
I> s the data entry done through a form in Access?

> if so then you could add data checking to the change event of the text 
box.

> Alternatively there is an ActiveX calendar which you can force the users 
t> o select the date, then you can derive the date format using the Format 
f> unction in VBA.

> Hope this helps
R> ob

I too had a similar issue due to an import function from an AS400 
application to our local Access DB.  What I ended up doing was writing 
code in VBA to convert the data before it was imported into Access.  I 
don't have the code handy, but if you would like it, please let me know!

Vince Kingston

  Return to Index