how to automatically set a variable to the system date

oohmygod831

Registered User.
Local time
Today, 21:17
Joined
Feb 16, 2005
Messages
43
i have a date variable that i wish to be automatically set to the system date for each new record. is this possible and if so how. Many thanks.
 
Do you really mean a variable or are you trying to timestamp a new record?
 
Last edited:
Set the default value for your variable to Date()
 
Set the default value for your variable to Date()

Let's get terminology set proper. A variable is something completely different from a date/time stamp in a field. Based on the question, I'm inclined to agree with RG in that it sounds more like you are wanting a date/time stamp on a record.

For that, create a field in your table (Date/Time datatype with General as the format).

Then you can set the default in the table or the form to be simply:

Now()
 
Last edited:
out of interest

date() gives you the date
time() gives you the time
now() gives you date AND time
 

Users who are viewing this thread

Back
Top Bottom