Toying with Dates

harrisw

Registered User.
Local time
Today, 18:31
Joined
Mar 27, 2001
Messages
131
I have a statement

Right(Format([tblJobs]![tobechargeddate],"mm"),2)

which retuens a 2 chr month.

How can I returnb the previous month in the same fashion

I've tried

Right(Format([tblJobs]![tobechargeddate],"mm"),2)-1

But this seems to return a 1 chr month, all be it correct

I want to be able to return the previous month as a 2 chr amount
 
Format(DateAdd("m",-1,[tblJobs]![tobechargeddate]),"mm")
 

Users who are viewing this thread

Back
Top Bottom