?
Solved

Create a form to filter data from a query (using multiple criteria) and generate a custom report.

Posted on 2016-09-20
4
Medium Priority
?
53 Views
Last Modified: 2016-11-05
Hi!

I'm pretty new to Access so I'm not sure this is even possible. My goal is to create a form that enables users to filter data (using one or more criteria) and create a custom report.

I created a report that has college students' names,  student year, the subject they are enrolled in, and a grade for that subject. All this data is coming from a separate query and each student has one row and one class.  My report has about 300 rows (1 for each student) but I want to allow users to view fewer results in the report based on specific categories in the query. For example, it would be great if a user can use a form to select one or more subjects and just view a report for students enrolled in English and Math.
0
Comment
Question by:Access Newbie
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 19

Accepted Solution

by:
Eric Sherman earned 1000 total points
ID: 41807813
Yes, that can be done but for an Newbie you may find it a bit challenging.

In summary ...
You would build list boxes on your search Form for all the criteria groups the user can filter on.  Then you would dynamically construct the select query base on what was selected in the list boxes.  

ET
1
 
LVL 4

Assisted Solution

by:bfuchs
bfuchs earned 1000 total points
ID: 41807973
The way I do it some times, have user filter the form by filter by form/selection or whatever method, then use the following to open the report.

If Me.FilterOn = True And Len(Me.Filter) > 0 Then docmd.OpenReport "ReportName",,,me.filter

Open in new window

1
 

Author Comment

by:Access Newbie
ID: 41808846
Thanks so much! So I ended up using multiple combo boxes (in a form) for the subjects and called them different names, then created a filtering query in which I used all combo box names as the criteria as in [Forms]![FilteringForm]![combo box 1] or [Forms]![FilteringForm]![combo box 2] etc. And it works :)
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question