Report filtered by form

  • Thread starter Lonnie via AccessMonster.com
  • Start date
L

Lonnie via AccessMonster.com

Trying to make a customizable report-- I have the form complete and linked to
my report.. but I am having problems filtering the info from the
corresponding table into the report.

one example is that on my form and report, I have a month listed, but in my
table, it goes by short date.. Is there a simple way to convert this so when
the user selects March for example, the records listed will be from 3/01 to
3/31 of the current year?

Also, another customizable field I have where they can filter between two
differen fields on the same table depending on how they choose (they can
filter the report either by machine or by operator), both of which are listed
on the table. Am having a problem figuring out how to make the report choose
between the two fields (i can easily type in one or the other, but making the
form selection choose it for me is passing me up)

I Hope someone can understand my random gibberish here== any suggestions are
greatly appriciated

Lonnie
 
M

Marshall Barton

Lonnie said:
Trying to make a customizable report-- I have the form complete and linked to
my report.. but I am having problems filtering the info from the
corresponding table into the report.

one example is that on my form and report, I have a month listed, but in my
table, it goes by short date.. Is there a simple way to convert this so when
the user selects March for example, the records listed will be from 3/01 to
3/31 of the current year?

Also, another customizable field I have where they can filter between two
differen fields on the same table depending on how they choose (they can
filter the report either by machine or by operator), both of which are listed
on the table. Am having a problem figuring out how to make the report choose
between the two fields (i can easily type in one or the other, but making the
form selection choose it for me is passing me up)


You can use the DateSerial function (see VBA Help) to get
your date. If the form month text/combo box contains the
month number, criteria could be:

Between DateSerial(Year(Date()),Forms!theform.thetextbox,1)
And DateSerial(Year(Date()),Forms!theform.thetextbox+1,0)

To generalize your criteria form, follow the guidelines in
this article:
http://allenbrowne.com/ser-62.html
 

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