Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can I auto Change Header Dates in queries

Status
Not open for further replies.

TJVFree

Technical User
Nov 22, 2010
236
US
I’m looking for a way to have my queries headers change their dates automatically each month or when the date changes.

I have a query that exports to an excel file. My query changes automatically each month with using the formula below

Code:
 Month12: Min((IIf([CORRESPONDENT_PURCHASE_DATE] Between DateSerial(Year(Date()),Month(Date())-12,1) And DateSerial(Year(Date()),Month(Date())-11,0),[CORRESPONDENT_PURCHASE_DATE])))

Basically when I run the update query and the new month populates the formula above I would like to have the header change.

Does anyone know of a way I can do this, or should I just forget this as an option

Thanks for taking the time to help

TCB
 
So you want to change from Month12 to something else like the date?

Any reason you are not using a crosstab query? If that is not what you are looking for, I completely misunderstand, can you clarify?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top