UtterAccess.com
We have detected that you are using an unsupported web browser. We recommend you to upgrade your web browser to get the most from UtterAccess forums.
Why should and how can I upgrade?
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Automatic Date Entry, Office 2007    
 
   
RobertJohn
post May 18 2010, 05:43 AM
Post #1

UtterAccess Member
Posts: 37



Hi all
I am using Access 2007
I have a Date/Time field (Edit_Date) on a form. I would like to have Today’s date entered as soon as I click in the field.

I tried :
Dim Edit_Date
Edit_Date = Date (I also tried Edit_Date = Today)
In both cases this set up the Date Picker which then involved a couple of clicks to actually enter Today’s date.
Is there a way to have the date entered directly without going through the date picker?
Thanks
Robert
Go to the top of the page
 
+
Peter46
post May 18 2010, 05:50 AM
Post #2

UtterAccess VIP
Posts: 7,489
From: Oadby Leics, UK



Why not set the default value of the textbox or the field to today's date.
=Date()
Go to the top of the page
 
+
Gustav
post May 18 2010, 11:05 AM
Post #3

UtterAccess VIP
Posts: 2,163



At the OnEnter event this should do it:
If IsNull(Me!Edit_Date.Value) Then
Me!Edit_Date.Value = Date
End If
If the date picker pops up, remove that feature in the property sheet of the textbox.
/gustav
Go to the top of the page
 
+
RobertJohn
post May 18 2010, 11:54 AM
Post #4

UtterAccess Member
Posts: 37



Gustav and Peter
any thanks. I'm now up and running.
Cheers
Robert
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Search  ·  Go to Top  ·  Lo-Fi Version Time is now: 20th September 2014 - 01:00 PM