Articles database
 
 
Web AnyArticles.com
Browse by Category:
 
  Subcategories
Data Recovery Data Recovery (126)
Games Games (238)
Hardware Hardware (431)
Personal Tech Personal Tech (455)
Software Software (964)


  Categories :
 
  Arts and Entertainment
  Automotive
  Business
  Communications
  Computers and Technology
  Finance
  Food and Drink
  Health and Fitness
  Home and Family
  Home Based Business
  Internet and Businesses Online
  Kids and Teens
  Legal
  News and Society
  Recreation and Sports
  Reference and Education
  Self Improvement
  Shopping and Product Reviews
  Travel and Leisure
  Womens Interests
  Writing and Speaking
  Random Category
  Funny stuff
  Settlements
  Funny stuff
Computers and Technology article : MS Access Database: Filter Data for a Report
 

Computers and Technology > MS Access Database: Filter Data for a Report

0 Reviews [ add review ], Article rating : 0.00, 0 votes. Author : Richard Killey

A common technique that I use to make a more professional looking user interface for filtering data for a report in an MS Access database, is to create a form to ask for criteria for the report. One example would be a report that is used to show data for a particular time period.

Step 1

Create a query to feed data to the report. Add any necessary parameters (like the "between [start_date] and [end_date]" style) and test.

Step 2

Create the report, using the query from step 1 as the record source. Test the report thoroughly. Obviously, you will have to answer the parameter questions manually, one at a time.

Step 3

Create a form with a text box for the starting date and another text box for the ending date. Use the button wizard to add a button that will preview the report created in step 2.

Step 4

Change the parameters in the query to this style:
Between [forms]![myform]![txtStartDate] and [forms]![myform]![txtEndDate]
making sure you use the actual names for the form "myform" and the text boxes "txtStartDate" and "txtEndDate".

That's it. And, no VBA coding was required.

(you may need to put some code behind the button that will verify the values in the various fields before starting the report, this would require VBA - you could also use a combo box to collect data for the report criteria)

Richard Killey is a Computer Database Programmer specializing in MS Access database development. Visit http://www.accessdatabasetips.com to read other articles of interest, and to download sample MS Access databases.


0 Reviews [ add review ], Article rating : 0.00, 0 votes. Author : Richard Killey
Rate this story : and read/post review(s)


Article reviews



Post your review
[ Note : no HTML/URLs - will removed automatically ]
Your name
Your comments


More articles from Computers and Technology

Add article | Manage Articles | Top Rated articles | Most Reviewed articles | Contact us | Links