Need help with date, newbie

PuJo

Oilfield Trash
Local time
Today, 04:53
Joined
Oct 12, 2006
Messages
16
Great forum, lots of smarts here.
I want to add 90 days to a date field, and have the new date in another field.

This is what I have on the form.

(feild 1) Previous PM Date (man. entered date)
(Feild 2) Next PM Date (I want this to auto update when a date is entered in (field 1)

I hope you understand what I am trying to say.

Thanks in advance,
PuJo
 
On whatever event you wish to use (like after update) run this.
Me.NextPMdate = DateAdd("d",90,Me.PreviousPMdate)

of course make sure you use your names
 
OK,
What am I missing?
Doesn't work, and what do you mean about "make sure you use your names"?
I hope I don't sound too stupid.
But thanks for the quick reply.
Pujo

"On The Bayou"
 
Me.NextPMdate = DateAdd("d",90,Me.PreviousPMdate)
The Me.NextPMdate (you need to substatue) your control name
Same with PreviousePMdate, I don't know what your control names are.
This would be in a event procedure.
If you want to use a macro, you have to use SETVALUE instead
 

Users who are viewing this thread

Back
Top Bottom