I'm having some problems with VB 6 and dates. The regional date setting for my system is set to: dd/MM/yyyy
System info:
PIII 1GHz
Microsoft Windows 2000 Professional 5.00.2195 SP2
Microsoft Visual Studio 6
Here is a sample of code that I ran in the VB 6 immediate window with results:
?Month(#01/05/2002#)
1
?Month(#12/05/2002#)
12
?Month(#13/05/2002#)
5
As you can see the month is the first 2 numbers; not what my regional settings indicate. Once the alleged month increases beyond 12, VB interprets the month to be the next field, 5.
The problem is I think a system wide issue. I have the same problems in MS Access XP, and when running SQL queries in VB on Access tables.
Any suggestions/help is much appreciated.
Thank you.
System info:
PIII 1GHz
Microsoft Windows 2000 Professional 5.00.2195 SP2
Microsoft Visual Studio 6
Here is a sample of code that I ran in the VB 6 immediate window with results:
?Month(#01/05/2002#)
1
?Month(#12/05/2002#)
12
?Month(#13/05/2002#)
5
As you can see the month is the first 2 numbers; not what my regional settings indicate. Once the alleged month increases beyond 12, VB interprets the month to be the next field, 5.
The problem is I think a system wide issue. I have the same problems in MS Access XP, and when running SQL queries in VB on Access tables.
Any suggestions/help is much appreciated.
Thank you.