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 » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Sub-Report, or other method?



 
 
Thread Tools Display Modes
  #1  
Old May 7th, 2004, 08:24 PM
clamfuddle
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use the same
date (set up as a parameter that the user is asked at selection time).
My report has one as the main report and the other query as a sub-report.

Unfortunately, this combination asks me the date like 4 different times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan


  #2  
Old May 7th, 2004, 08:41 PM
Rick B
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

You would need to build a small form with an unbound field. Have this field
open when the report is requested. In your queries and report, pull the
value from the field. Have a button on the form that wqill allow the user
to make an entry and then have the form hide itself.

In the reports onclose property, set the value of the field to "" so it will
be blank when the next user opens it, and then have the form close.

Rick B



"clamfuddle" vader1 at flash.net wrote in message
...
Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use the same
date (set up as a parameter that the user is asked at selection time).
My report has one as the main report and the other query as a sub-report.

Unfortunately, this combination asks me the date like 4 different times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan



  #3  
Old May 7th, 2004, 09:34 PM
PC Datasheet
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

It's very likely since you need the same date in the main report and the
subreport that you may need a redesign of your tables. If designed correctly,
the subreport will track the main report. This means that when you display a
record for a selected date in the main report, the records for the same date
should automatically be displayed in the subreport.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com


"clamfuddle" vader1 at flash.net wrote in message
...
Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use the same
date (set up as a parameter that the user is asked at selection time).
My report has one as the main report and the other query as a sub-report.

Unfortunately, this combination asks me the date like 4 different times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan




  #4  
Old May 7th, 2004, 10:30 PM
clamfuddle
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

I don't think I follow -

If I don't have a date criteria in the subreport (tied to a query), it pulls
every record
in the table that matches that client, etc. But not by date.

What I have done:

Created query1 that includes and groups on Client, Subproject, SaleType and
Count(SaleType) -
with a parameter called [SALE_DATE] that causes a dialog box to pop up.

Created query2 that has the same data, but grouped differently (Client,
SaleType and Count(SaleType)
with a parameter called [SALE_DATE]. I was hoping that since it was a
sub-report that the SALE_DATE
given in query1 would be passed to query2 (same parameter name).

Then I created a report based on query1, and inserted query2 as a sub-report
in the client footer.

What I want to happen - launch the main report - it triggers the dialog box
to ask for the sale date and
then it creates the report that matches this date.

What I get - launch the main report, it triggers the dialog box 6 or 7 or
more times and then finally creates
the report that matches this date. But if I go to page 2, I get the dialog
box again.

I'm pretty good on queries, and tables and such - just have never had much
reason to do formal "reports"

Lost in space, and THANK YOU for helping me with this problem.

Bryan

"PC Datasheet" wrote in message
nk.net...
It's very likely since you need the same date in the main report and the
subreport that you may need a redesign of your tables. If designed

correctly,
the subreport will track the main report. This means that when you display

a
record for a selected date in the main report, the records for the same

date
should automatically be displayed in the subreport.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com


"clamfuddle" vader1 at flash.net wrote in message
...
Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use the

same
date (set up as a parameter that the user is asked at selection time).
My report has one as the main report and the other query as a

sub-report.

Unfortunately, this combination asks me the date like 4 different times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan






  #5  
Old May 7th, 2004, 10:45 PM
PC Datasheet
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

I can't tell from the info you provided exactly what you are doing. The main
report should pull up sales records for a particular date. The subreport should
pull up the details of each sales record. As you navigate from sales record to
sales record in the main report, the subreport should track the main report with
out any user input.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com



"clamfuddle" vader1 at flash.net wrote in message
...
I don't think I follow -

If I don't have a date criteria in the subreport (tied to a query), it pulls
every record
in the table that matches that client, etc. But not by date.

What I have done:

Created query1 that includes and groups on Client, Subproject, SaleType and
Count(SaleType) -
with a parameter called [SALE_DATE] that causes a dialog box to pop up.

Created query2 that has the same data, but grouped differently (Client,
SaleType and Count(SaleType)
with a parameter called [SALE_DATE]. I was hoping that since it was a
sub-report that the SALE_DATE
given in query1 would be passed to query2 (same parameter name).

Then I created a report based on query1, and inserted query2 as a sub-report
in the client footer.

What I want to happen - launch the main report - it triggers the dialog box
to ask for the sale date and
then it creates the report that matches this date.

What I get - launch the main report, it triggers the dialog box 6 or 7 or
more times and then finally creates
the report that matches this date. But if I go to page 2, I get the dialog
box again.

I'm pretty good on queries, and tables and such - just have never had much
reason to do formal "reports"

Lost in space, and THANK YOU for helping me with this problem.

Bryan

"PC Datasheet" wrote in message
nk.net...
It's very likely since you need the same date in the main report and the
subreport that you may need a redesign of your tables. If designed

correctly,
the subreport will track the main report. This means that when you display

a
record for a selected date in the main report, the records for the same

date
should automatically be displayed in the subreport.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com


"clamfuddle" vader1 at flash.net wrote in message
...
Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use the

same
date (set up as a parameter that the user is asked at selection time).
My report has one as the main report and the other query as a

sub-report.

Unfortunately, this combination asks me the date like 4 different times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan








  #6  
Old May 7th, 2004, 10:50 PM
clamfuddle
external usenet poster
 
Posts: n/a
Default Sub-Report, or other method?

OK, Thanks for trying - I'll keep plugging away.

Bryan

"PC Datasheet" wrote in message
ink.net...
I can't tell from the info you provided exactly what you are doing. The

main
report should pull up sales records for a particular date. The subreport

should
pull up the details of each sales record. As you navigate from sales

record to
sales record in the main report, the subreport should track the main

report with
out any user input.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com



"clamfuddle" vader1 at flash.net wrote in message
...
I don't think I follow -

If I don't have a date criteria in the subreport (tied to a query), it

pulls
every record
in the table that matches that client, etc. But not by date.

What I have done:

Created query1 that includes and groups on Client, Subproject, SaleType

and
Count(SaleType) -
with a parameter called [SALE_DATE] that causes a dialog box to pop up.

Created query2 that has the same data, but grouped differently (Client,
SaleType and Count(SaleType)
with a parameter called [SALE_DATE]. I was hoping that since it was a
sub-report that the SALE_DATE
given in query1 would be passed to query2 (same parameter name).

Then I created a report based on query1, and inserted query2 as a

sub-report
in the client footer.

What I want to happen - launch the main report - it triggers the dialog

box
to ask for the sale date and
then it creates the report that matches this date.

What I get - launch the main report, it triggers the dialog box 6 or 7

or
more times and then finally creates
the report that matches this date. But if I go to page 2, I get the

dialog
box again.

I'm pretty good on queries, and tables and such - just have never had

much
reason to do formal "reports"

Lost in space, and THANK YOU for helping me with this problem.

Bryan

"PC Datasheet" wrote in message
nk.net...
It's very likely since you need the same date in the main report and

the
subreport that you may need a redesign of your tables. If designed

correctly,
the subreport will track the main report. This means that when you

display
a
record for a selected date in the main report, the records for the

same
date
should automatically be displayed in the subreport.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications

www.pcdatasheet.com


"clamfuddle" vader1 at flash.net wrote in message
...
Hi.

How can I pass a parameter to both the Report and the Sub-Report?

I have two queries based on the same table and I want them to use

the
same
date (set up as a parameter that the user is asked at selection

time).
My report has one as the main report and the other query as a

sub-report.

Unfortunately, this combination asks me the date like 4 different

times
prior to
actually creating the report.

What am I doing wrong? Any other suggestions?

Thanks!

Bryan










 




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 08:29 AM.


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