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
Solved

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

Posted on 2016-09-20
4
38 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
4 Comments
 
LVL 19

Accepted Solution

by:
Eric Sherman earned 250 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 250 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

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

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

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
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…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

829 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