date function

H

hazen

Hi,

I have this function : "Number: Count(IIf([TrackDate] Between
#6/1/2003# And #6/30/2003#,[TrackDate]))", it is calculates orders
within particular time frame -1 month. Right now it is calculates orders
within June. I am trying to right a generic function instead of "Between
#6/1/2003# And #6/30/2003#", so I would not have to go and change the
number of the month every time. Is there exists this kind of function?

Thanks!
 
J

John Spencer (MVP)

How about something like:

Abs(Sum(Format([TrackDate],"yyyymm") = Format(Date(),"yyyymm")))

This would do the current month. If you need to do something else, could you be
more specific about it?

Do you want it to count for each month when you are doing an entire year? Or do
you just want it to do a specific month (last month, this month)?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top