Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / May 2008

Tip: Looking for answers? Try searching our database.

enter a date without leading zero month

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
TransProg - 28 May 2008 16:13 GMT
A user wants to enter dates without the leading zero in the month. Ex.
5/28/2008
The field type is Date/Time and the date is being entered on a form. How
would I set this up in a form?
Thanks.
Klatuu - 28 May 2008 17:16 GMT
Use an Input mask for the control as
99/99/0000;0;_

so if you want to put in today's date you would type
5/282008
and it would become
5/28/2008

Signature

Dave Hargis, Microsoft Access MVP

> A user wants to enter dates without the leading zero in the month. Ex.
> 5/28/2008
> The field type is Date/Time and the date is being entered on a form. How
> would I set this up in a form?
> Thanks.
TransProg - 28 May 2008 18:11 GMT
Thanks Klatuu! That does work. Is it possible to enter the date that way
without the slashes as well?

> Use an Input mask for the control as
> 99/99/0000;0;_
[quoted text clipped - 9 lines]
> > would I set this up in a form?
> > Thanks.
Klatuu - 28 May 2008 18:15 GMT
Not really,  you can always use the same input mask and enter
05282008
(same number of keystrokes)
But, in either case it doesn't have any effect on how the date is stored.  
All dates are stored in date/time fields as a floating point decimal number.
Signature

Dave Hargis, Microsoft Access MVP

> Thanks Klatuu! That does work. Is it possible to enter the date that way
> without the slashes as well?
[quoted text clipped - 12 lines]
> > > would I set this up in a form?
> > > Thanks.
John W. Vinson - 28 May 2008 21:55 GMT
>Thanks Klatuu! That does work. Is it possible to enter the date that way
>without the slashes as well?

Well... what date would you want entered if the user typed 12308?
January 23 (1/23/08) or December 3 (12/3/08)?

It's ambiguous. You MUST give Access some unambiguous way to determine which
digit is in the month and which digit is in the day - either by typing all the
digits (012308 or 120308), or by typing the slashes.
Signature


            John W. Vinson [MVP]

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.