Subreport?
Jun 16, 2006
I've created a database which I'm pretty much using as a point of sales terminal.. it does sales, returns, expenses etc. I have created a report for each one of these (sales, returns...) which can be printed off at the end of each day.
At the moment, if there is no data in one of the reports, I have put a bit of code in the NoData event of the report that will make a label visible saying "no sales/returns/expenses for this date".
I am trying to combine all of these reports into one report so the user can click a button to open a general "End of Day" report. The problem with making them all subreports is that if there is no data in a subreport, nothing will be displayed in that subreport.
Is there anyway to force access to display a subreport regardless of whether is has data in it? or can anyone see another option which i have missed?
View Replies
ADVERTISEMENT
Apr 6, 2006
Is there any way to add a dropdown box or something that determines that a subrecord is active/completed, and then have a way to jump straight to the one that is active by clicking a button on the record? In the example I attached, I want to be able to click on the button above the tab and have it switch to that tab and open the first record it finds that has "Active" selected.
View 1 Replies
View Related
Oct 28, 2004
i have a subreport on a header of one group and sometimes has data and sometimes hasnt.I would like that when subreport is empty it doesnt show subreport header but I dont know how.code Me!subreport.Visible = Me!subreport.Report.HasData
doesnt work properly since it always has data,just not on every page....
View 1 Replies
View Related
Dec 5, 2004
I have created a report and the subreport. The information from the subreport will not show up when I bring the report up. I created a query with the info needed for the subreport but know I'm missing linking something somewhere? Any help?
Thanks-
View 2 Replies
View Related
Aug 16, 2005
I'm new to access, I've done database work before just not with this package, I have only one small problem and this should be an easy one...
Without going into too much detail, i have a report that generates a list and calculates a few totals based on a date range inputed by a user. (I do this by using the "Between[Report Start Date] and [Report end Date]" statement as my criteria for the DATE field in my SQL statement.)
Inside that report i would like to include a subreport which summarizes the data of the main report. this subreport needs to display data based on the same date range as the main report. I simply cannot figure out how to get the subreport to use the same date range without prompting the user to type it in twice. I have another report that generates a subreport based on a users last name, this subreport works just fine ( I think this is because there is only one user inputted field and not two as with the date range.)
Both the subreport and the main report calculate the correct data when run independently, so I am confident they whole thing will work as soon as I know how to share the user inputted criteria.
If you have any answers please reply ASAP, it would be really appriciated.
View 1 Replies
View Related
Feb 6, 2006
Hi all!
I'm kinda stuck in a rut with one of my reports.
I have a loan database, and I need a detailed report with the borrower's name, repayment details according to their loan serial number. In the same report, I will also need details of all other people whom they have acted as guarantors for.
So what I have is a form for the user to select the person they would like to check on. Based on the user input, it generates a report with the borrower's details, as well as loan details. I then have a subreport which lists all repayments made based on the loan serial number, which works fine.
I'm stuck, however in trying to create another subreport in the main report to generate all details pertaining to loans which the person has acted as a guarantor. I tried linking the Guarantor's name to the form for the input, but in doing this, I get the guarantor's details, but my loan repayment subreport returns a blank.
Any suggestions or ideas, please?
It will be greatly appreciated! Been stuck with this for a few days now.
Thanks again!
View 11 Replies
View Related
Mar 21, 2006
I have a report open that contains a subreport. I am trying to run the following code from a form to change the filter on this subreport.
Reports("rptStaffDetail").Controls("rptStaffReportSub").Report.Filter = "MasterCourseType = 1"
I get the error 'The setting you entered isn't valid for this property'
I should be able to access the subreport this way as the following code ran from the form works fine.
Reports("rptStaffDetail").Controls("rptStaffReportSub").visible = False
View 2 Replies
View Related
Jun 15, 2005
I have a Report linked with a SubReport. I would like to cancel viewing this Report if my SubReport Has No Data.
i tried this code but the report just shows up. Any Ideas?
Private Sub Report_Open(Cancel As Integer)
On Error GoTo Err_Trapper
If Reports![qryRepCurOrgProjsSR].Report.HasData = 0 Then
Cancel = True
End If
Err_Trapper:
MsgBox Err.Description
Exit Sub
End Sub
Ok i got an error message. Yoy entered an expression that has an invalid Reference to the hasData property.
Ive tried using a text bpx on my main report and putting a control source as
=IIf(qryRepCurOrgProjsSR.Report.HasData,0,"Nothing")
Then in my Report Open Event i put the code below. But it fails me still.
If trim(Me.MyText) = "Nothing" Then
MsgBox "The Report Is Cancelling....."
Cancel = True
Exit Sub
End If
View 3 Replies
View Related
Jun 8, 2006
I tried looking through the threads to find something that is relevant to my situation.
I am having trouble with a form where i need to select a name in one combobox and a month in another and then upon which a subreport displays the records for that name and month on a subreport which can then be added extra records or old records edited.
Does anyone know how to do this or can maybe just give me some code or point of reference to do this. I have tried but all attempts return no results.
Any help is much appreciated. Thx
Frans
View 1 Replies
View Related
Oct 6, 2004
I have a report with the same subreport appearing twice. The two instances of this subreport have different queries.
For instance boys and girls information. The only difference is the queries (one would have sex=M the other sex = F)
Is there any way of doing this without copying the subreport and giving it another name (this of course would allow me to assign different queries to each subreport).
Thanks
View 3 Replies
View Related
Nov 25, 2004
I am trying to do a simply calculation on a report which uses a value from a subreport. The main report is called rptAllProjectsStatus the sub report is called rptAllProjectsStatusExp, and the box from the sub-report is called tboAmount which is controlled by query.
In the main report I have a box whose control source is
=[tboFixedFee]-[tboSumStaffingCost1]-rptAllProjectsStatus!rptAllProjectsStatusExp!tboAm ount
But it doesn't recognise this formula - what am I doing wrong?
I know the problem is with the latter part of the formula (in connection with the sub-report), as if I remove this part, the rest of the calculation works fine.
thanks
S
View 6 Replies
View Related
Oct 22, 2007
I have page numbers in a subreport. How do I get them to update to match the correct page numbers for the report?
Thank you.
View 2 Replies
View Related
Jun 20, 2014
So I am adding a chart (on a subreport) to a report that has multiple subreports already. I have gotten the chart to show up correctly on the report, but now 2 of my other subreports are not working. I am being prompted to input parameters for these subreports that used to pull their parameters (between dates) from the main report.
I read somewhere that charts master/child linking doesn't work but I'm not sure if that applies to subreports with charts on them, or just charts in general. I've tried changing the query on the chart subreport a little without luck. Is this likely some glitch thing? Should I keep trying to alter the query or maybe there is some other work around option?
View 7 Replies
View Related
Jun 15, 2014
I am creating an end of week report, which needs information from Sat-Fri, so basically it will be one sub form, but used 6 times.
I'd prefer not to have to make 6 subforms, with 6 queries, but rather using 1 subform and 1 query 6 times.
For example, on the parent form, I will add the subforms, and name them "Sat", "Mon", "Tue" etc...
I want to make one query that filters the information based on the name of the subform:
Day: Format([Date],"ddd")
Where: Day = Me.Name
I can't figure out what to ask the query to refer to, to retrieve the name of the subform it's currently sat in.
View 3 Replies
View Related
Mar 5, 2006
I have a report named rpt100 with two subreports srpt100a and srpt100b. The subreports are based on query qry100a and qry100b. Both queries are based on tbl100. I removed a field named 'Comment' from tbl100, as it wasn't useful; Also removed the fieldname from both qry100a and qry100b. When opening rpt100 a parameter dialog opens asking for data on the deleted fieldname 'Comment'. The field 'Comment' was never used in the report or subreports.
Inspection of the subreport fieldlist shows field 'Comment' still present.
How, other than remaking the rpt100 and both srpt100a and srpt100b, do I remove the field 'Comment'?
Gunner...:confused:
View 1 Replies
View Related
Aug 26, 2004
I have a report that has an embedded subreport. The main report is grouped on client id. The aim is print a different client on a different page (I have the force new page after section set). The subreport is put into the section footer. The problem is that the subreport is based on a different query. How can I filter the subreport query result to show only the information for the client specified in the main report.
thanks
newbie
View 3 Replies
View Related
Oct 2, 2004
I haev a report with 15 sub reports. I have to use Visual Basic to format the sub reports. I know how to do the formatting (see below) but what I would like to do is have one function (Public) that I can pass the subReport name to and have the formatting happen. This would be mush easier to maintain than copying the code below into on_print events of all 15 sub reports.
Has anyone done this and have an example??
Thanks
--------------------------------------------------------------------------------------
Private Sub GroupHeader0_Print(Cancel As Integer, PrintCount As Integer)
Dim widthOfBox, startLeftSide
startLeftSide = 0.017
widthOfBox = 0.21
Me.ScaleMode = 1
Me.ForeColor = 0
'Repeat the following line of code for each vertical line
' 1*1440 represents 1 inch
' Me.Line (0 * 1440, 0)-(0 * 1440, 14400) 'Draws line at Left Margin
Me.Line ((startLeftSide * 1440) + widthOfBox * 0 * 1440, 0)-((startLeftSide * 1440) + widthOfBox * 0 * 1440, 14400) 'Draws line at Left Margin
Me.Line ((startLeftSide * 1440) + widthOfBox * 1 * 1440, 0)-((startLeftSide * 1440) + widthOfBox * 1 * 1440, 14400) ' Draws next line
Me.Line ((startLeftSide * 1440) + widthOfBox * 2 * 1440, 0)-((startLeftSide * 1440) + widthOfBox * 2 * 1440, 14400) ' Draws next line
Me.Line ((startLeftSide * 1440) + widthOfBox * 3 * 1440, 0)-((startLeftSide * 1440) + widthOfBox * 3 * 1440, 14400) ' Draws next line
Me.Line ((startLeftSide * 1440) + widthOfBox * 4 * 1440, 0)-((startLeftSide * 1440) + widthOfBox * 4 * 1440, 14400) ' Draws next line
'the 14400 is an arbitrary number to increase the line to the max of a
'section.
End Sub
View 1 Replies
View Related
Dec 5, 2004
Ok I've browesed this forum and can't seem to find anything that will work.
I have a report that includes 7 subreports with a page break before each subreport.
I want to hide, or disable the page breaks and subreports if a give subreport is empty.
Any ideas on how to do this?
View 2 Replies
View Related
May 8, 2013
I have a main report with 3 sub reports.The Sub reports have onload events that fill up the text boxes with VBA code. When I open the sub report alone everything works fine. But when I open the main report, the on load of the subreport wont work.
View 1 Replies
View Related
Feb 12, 2014
I have a report with several subreports. I need to total the subreports onto the main report. How do I refer to the control on the subreport?I know that with a form / subform I would use: Me!Subform1.Form!Controlname.But simply replacing 'Form' with 'Report' doesn't seem to work.
View 1 Replies
View Related
Jun 16, 2014
I have a main report with several subreports. Some subreports have other nested subreports. all of the reports and subreports are based on queries. when a query returns no values, i would still like for the reports and subreports to display in print preview. (currently, they display in report view but not in print preview.)
I tried a few things:
1) I set all report section can shrink options to "No" - (this did not work)
2) I set the can shrink options for all textbox controls, within each report section , to "No" - (this did not work)
3) I moved all controls from the details section of the subreport to the report header section - (when I did this, I got the subreport to show in print preview when the query for a single subreport returns no values but when i have a subreport with nested subreports that have no value, none of them show up in print preview)
I've searched...moving the controls from the details to the report header was the best thing i could find, but again, this only works with a single subreport and not with multiple nested subreports.
View 8 Replies
View Related
Oct 21, 2013
I would like to create a report based on a query. The first part is simple enough. However within this query I have a 'Count field' (a total of the number of duplicated this record has appeared in the table). And would like to create a subreport (if possible) based on that value for example. if count > 1 then show subreport.
My question therefore; is the above possible? How would I go about linking this logic with the subreport
View 1 Replies
View Related
May 1, 2013
In Access 2010 I am previewing a customer report. I also try to give users the choice of seeing history sub records for any given customer. I have a selection dropdown box where they can chose ALL, 5, 10 or 15 in a report. To this end I set the record source in the "Open" event for the subreport. if I want all records it works fine, but as soon as I put in "SELECT TOP 5" the subreport goes invisible. I have tested the query directly and it works fine. I'm sure this worked in Access 2007
View 3 Replies
View Related
Apr 19, 2013
I have a report with 2 subreports on it. One of the subreports does not show on the report preview unless I set a breakpoint in the report's code. Set a breakpoint in the code (for no other reason), hit the breakpoint, continue, and the report works fine from then on, until you close the database and open it again, even if you remove the breakpoint. The other subreport, which is similar, always shows fine.
I can't find out what's wrong by setting a breakpoint.
View 1 Replies
View Related
Jul 25, 2015
I have a report that calls a subreport. In most instances, the subreport will have no data and I won't want to show the subreport. I've tried various ways to deal with this:
1) Make the subreport property on the main report the minimum height and set CanGrow = Yes
2) Use the Report_NoData event on the subreport and add the code 'Cancel = 1'
3) Make all the fields on the subreport the minimum height and set CanGrow = Yes
None of these seem to work. I don't have any headings on the subreport, so the only price I'm paying is adding a gap onto the main report the size of one detail line of the subreport. Still, it leaves the report lacking professional quality.
View 4 Replies
View Related
Jul 6, 2005
Below is the working version of the code works for single report filtering. say a report called "rptduedate_census2" and i can filter out using form instead of hard coding query of that report (say lastname=form!frmsample!txtlastname). I dont want to hard code query and there are reasons for that.
I am using a Main report called "rptDueDates_Dept' and there are about 10 different subreports (see print screen). The main report is not bound to any query. It has many subereport. Each subreport is bound to some query and i need to be able to filter them before data appear on the main report. Am i making any sense, LOL.
How can I implement my working code below to do this. PLEASE PLEASE PLEASE HELP. I AM NEW TO ALL THIS. I have attached a print screen of the main report, just to show how i put subreports in their.
===== MY WORKING CODE ======
Private Sub cmdPrv_Click()
Dim strFilter As String
strFilter = "[Mail_Census_Date] BETWEEN #" & txtStartDate & " # AND # " & txtEndDate & " # "
' Apply the filter and switch it on
If SysCmd(acSysCmdGetObjectState, acReport, "Report") <> acObjStateOpen Then
DoCmd.OpenReport "rptduedate_census2", acViewPreview
With Reports![rptduedate_census2]
.Filter = strFilter
.FilterOn = True
End With
DoCmd.Restore
Exit Sub
End If
End Sub
View 1 Replies
View Related