Query String on a Report

C

Chefjay22

Hello there! I have a quick question. I have an unbound field on a report
that needs to display a max value from a table. Here is my example:

ReportName: rptTest
unbound field: MaxDate

I need to query tblDates and grab the max record in field StartDate and
display it in the unbound field MaxDate. I know how to do this using a
subreport based off a query, but I would like to learn a new way... any
ideas? Thank you!
 
M

Marshall Barton

Chefjay22 said:
Hello there! I have a quick question. I have an unbound field on a report
that needs to display a max value from a table. Here is my example:

ReportName: rptTest
unbound field: MaxDate

I need to query tblDates and grab the max record in field StartDate and
display it in the unbound field MaxDate. I know how to do this using a
subreport based off a query, but I would like to learn a new way... any
ideas?

How about just using an expression in the text box:

=DMax("StartDate", "tblDates")
 
F

fredg

Hello there! I have a quick question. I have an unbound field on a report
that needs to display a max value from a table. Here is my example:

ReportName: rptTest
unbound field: MaxDate

I need to query tblDates and grab the max record in field StartDate and
display it in the unbound field MaxDate. I know how to do this using a
subreport based off a query, but I would like to learn a new way... any
ideas? Thank you!

In an unbound control:

=DMax("[StartDate]","tblDates")
 

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