Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report linked to Form comes up blank-

Status
Not open for further replies.

carlcwc

Technical User
Sep 3, 2002
43
0
0
US
My main report is made up of 14 sub reports linked to queries that comes from a single table. I use a form to search by date the data I want(the queries are set up to search by date). My problem is that when I use the SEARCH BY DATE form the main report is blank with only the headers of each sub report. Only when I open the main report without the form and enter the begin/end date for all 14 subreports does the information show up on the main report. I've double checked for typos,etc... and can not find anything obvious.
Your assistance is appreciated.
 
In the report, how are you tring to link to the form for a "Filter" critera? (I think within this question is your solution.)

--James junior1544@jmjpc.net
Life is change. To deny change is to deny life.
 
How are you linking that date search form to all those subreports?
 
I'm not..and the Filter On is set to No.
 
The form is linked to all the queries that make up the subreports on the main report.
the criteria on each of the 14 queries has the following code:
Between [Forms]![frmSelectDate]![txtStartDate] And [Forms]![frmSelectDate]![txtEndDate]

The form uses the following code:

Private Sub opnrpt_Click()
On Error GoTo Err_opnrpt_Click

Dim stDocName As String

stDocName = "rptOutreachTotal"
DoCmd.OpenReport stDocName, acPreview

Exit_opnrpt_Click:
Exit Sub

Err_opnrpt_Click:
MsgBox Err.Description
Resume Exit_opnrpt_Click

End Sub
Private Sub Command5_Click()
On Error GoTo Err_Command5_Click

Dim stDocName As String

stDocName = "rptOutreachTotal"
DoCmd.OpenReport stDocName, acPreview

Exit_Command5_Click:
Exit Sub

Err_Command5_Click:
MsgBox Err.Description
Resume Exit_Command5_Click

End Sub

Hope you can help
thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top