Disappearing default date =-)

Timoty

Registered User.
Local time
Today, 15:15
Joined
Jul 29, 2003
Messages
105
Is there a way on a form, to have the filed default to today’s date when a person enters that field. A confirmation asks if you want to keep that days date, and if they select no it clears the space?

I want a form to default with that days date. However, I don’t want it to stay at that date without any kind of user intervention because ‘lazy’ people may not override the date if it is actually incorrect. I hate to ‘punish’ everyone with an extra step but I am unsure of how else to do it unless I just leave it blank and let them fill it in. The majority of the time the entry will be that day’s date.

Anyone else have a better solution, I would love to here it.

Thanks
 
Well what you can do is.. set that textbox's default value to =date() in the form design. Then add the following to the textbox's "on got focus" event

If msgbox ("Would you like to change the date?",vbyesno) = vbyes then
me![your textbox] = ""
end if

it should work i guess.

Regards,
 
The thing is, if the person doesn't touch the box, it will stay at today's date and if the date was supposed to be something other than that day's date it will remain incorrect. The only solution I can think of is to have a code that on got focus inputs that days date and asks then pops up a message that syas do you want to remain at todays date. If yes it stays if no it goes blank. Unless someone can think up something easier I will go with that.
 
Point well taken. For those that forget to put in a date, well they will be logged in teh background and managemnet can deal with them.
 

Users who are viewing this thread

Back
Top Bottom