A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Linking forms and reports.



 
 
Thread Tools Display Modes
  #1  
Old April 12th, 2010, 10:06 PM posted to microsoft.public.access.tablesdbdesign
Rose
external usenet poster
 
Posts: 262
Default Linking forms and reports.

I am trying to find the easiest method to write code which would allow me to
open a report from a form linking up to five fields. For example: I have a
form linked to a table that contains hundreds of jobs (tblJobs). In the form
I want to be able to click a command button and pull up a report on the
potential clients (tblClients) who fit the matching criteria in the current
form. The criteria fields may be City, Job Category, Age Requirement, etc.
Any thoughts?
--
Rose
  #2  
Old April 13th, 2010, 12:58 AM posted to microsoft.public.access.tablesdbdesign
Allen Browne
external usenet poster
 
Posts: 11,706
Default Linking forms and reports.

The most flexible way is to use the WhereCondition of OpenReport, so you can
use any combination of criteria that the user chose to fill out on your
form.

Here's a really simple example of how the WhereCondition works, using just
one field:
http://allenbrowne.com/casu-15.html

Here's an example that shows how to create the WhereCondition from several
criteria:
http://allenbrowne.com/ser-62.html
That one includes a downloadable example that shows the matching results in
a form. The process for filtering the report is identical.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.


"Rose" wrote in message
...
I am trying to find the easiest method to write code which would allow me
to
open a report from a form linking up to five fields. For example: I
have a
form linked to a table that contains hundreds of jobs (tblJobs). In the
form
I want to be able to click a command button and pull up a report on the
potential clients (tblClients) who fit the matching criteria in the
current
form. The criteria fields may be City, Job Category, Age Requirement,
etc.
Any thoughts?
--
Rose


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 01:18 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.