470,585 Members | 1,617 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,585 developers. It's quick & easy.

Using non American date formats with Microsoft Access and Visual Basic

Date problem.

Using non American date formats with Microsoft Access and Visual Basic.

I set my regional settings to English(Ireland) or English(United Kingdom)
and my date appears in Access as DD/MM/YYYY.
However if the day is less than 12 the day then becomes the month
e.g. 3 July 2003 is displayed in Visual Basic as 7 March 2003.
So if I have two records with different dates as such 6/8/03 and 15/8/03
the first date is 8 June 2003 and the second is 15 August 2003.
If I reset the Regional settings on the PC back to English(United States)
the problem goes away as long as I'm happy with MM/DD/YYYY format, but of
course I can't insist on an end users PC's regional settings being changed
in order for my application to run properly.

I've tried combinations of formatting the date in Access and formatting the
value returned in Visual Basic but I don't feel I'm winning the battle.
I could format the date and save it as a string and vice versa but I'm
hoping that isn't the only solution. I'm sure people have encountered this
a million times already. Any help on how you would approach this problem
would be greatly appreciated.

Kind regards,
Ray Brennan.
Dublin, Ireland.
Jul 17 '05 #1
0 3540

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Richard Hollenbeck | last post: by
121 posts views Thread by typingcat | last post: by
9 posts views Thread by Bob Achgill | last post: by
9 posts views Thread by Simon Harvey | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.