PBrown
Thanks for the details. I have set my section heights to exactly the same as yours. I also made my table to show exactly the same number of items as you have. My report is printing perfectly, with the pages breaking appropriately and the "Continued" label only appearing when it is necessary. So I don't quite get why mine and yours are operating differently?
Do you have any sensitive data in your database that would preclude your sending it to me? If not, I'd be happy to have a look at it.
As for the Knowledge Base article 306127, did you notice that early on in the instructions it said to set the ForceNewPage property to "Yes" in the Group Footer? Doesn't that in itself defeat what you want?
That must have slipped by me (Force new page)...
As for sending the report, no can do. The DB is up to 14MB and even when zipped it only goes down to ~4MB and we can not send e-mail outside the company that is over 2MB.
However, I did find something else in the Microsoft Knowledge base. It will not put continued in the actual header, but it can place it in the page header. However, I am having difficulty in getting it to work. Article # 182823. It says that reports may require more work, but I don't even know where to start...
Your help is greatly appreciated!
As for Article 182823, I just had a quick peek. Did you notice that it says this applies to Access 97 (aren't you in Access 2000)? Also, near the very bottom of the article, it says you need to set the Force New Page property to "Yes" to control the layout. Back to the same old "force new page" deal. It might not be Murphy's Law, but it must be Access'.
As an alternative, why don't I send you what I worked up. If you post your e-mail address here, I'll ship you my little db I worked up for this. Don't put your e-mail address in the normal form. Rather, put it like this "jsmith*at*promises.com" That will encrypt it a little.
I had the code from the article working, however, I accidently made that Copy of the FE into a MDE file. Therefore, can not recover the report or the Module. Any suggestions?
As for the e-mail, I would like to save that for a "last option" since all incoming e-mails are screened and we must account for any they deem "Personal".
PBrown
I just worked with the code from the Article 182823 also, just to see. And it worked fine. And you don't have to set the section heights at what they say, the heights can be anything.
It's pretty straightforward. Just follow the instructions. Just keep the Knowledge Base article open and cut and past in the code for the Module into your new module. When you have done that, click on Save, and it will give you the option of naming your module.
Now, as for making your FE stuff into an mde file, ouch. Do you have a backup of your database? If you don't, I'm not sure whether or not you can get back. But I haven't tried it. You may want to make another post about that situation.
I understand the e-mail reluctance. No problem. What bugs me is that something works here but not at your end, and I'd like to understand why. If you have an e-mail address at home, I could ship my little sample to you there. Your call.
As for the cut and paste of the code,
When you cut and pasted, did
=SetContinuedLabel (Report)
turn into:
=SetContinuedLabel([Report])
for some reason, on both the page header and footer, (report), automatically turned into ([report]). I believe this is why the "Continued...." is only appearing on the last page.
Not yet.....
Waiting for CIS to recover the file. I am currently attempting to recreate what I did on a copy, but am having trouble. Below is what I currently have, perhaps you can see or dont' see a needed part:
Module: Continued
Option Compare Database
Option Explicit
Public CurrentGroupVal As String
Function SetGlobalVar(Inreport As Report)
CurrentGroupVal = Inreport!SetGroupVal
End Function
Function SetContinuedLabel(Inreport As Report)
If Inreport.Page <> 1 Then
Inreport!ContinuedLabel.Visible = _
IIf(Trim(Inreport!CheckGroupVal) = _
Trim(CurrentGroupVal), True, False)
End If
End Function
Report:
Page Header On Print: =SetContinuedLabel([Report])
Page Footer On Print: =SetGlobalVar([Report])
Text Box in Header: CheckGroupVal
Control Source: Area
Visible: No
Text Box in Footer: SetGroupVal
Control Source: Area
Visible: No
Can you see where I may have missed something?
Other than that, the grouping is set to Keep With Fist Detail.
I hope to have my restored database shortly after lunch, but who knows.....
PBrown
Well, I did spot a couple of things.
1. You should have a capital "R" in report in "InReport"
2. My setting for Sorting and Grouping is Group On "each value", and Keep Together is "No". However this may work differently in Access 97. Not sure
Here's the code for the module if you just want to copy it and paste it in.
Option Compare Database
Option Explicit
Public CurrentGroupVal As String
Function SetGlobalVar(InReport As Report)
CurrentGroupVal = InReport!SetGroupVal
End Function
Function SetContinuedLabel(InReport As Report)
If InReport.Page <> 1 Then
InReport!ContinuedLabel.Visible = _
IIf(Trim(InReport!CheckGroupVal) = _
Trim(CurrentGroupVal), True, False)
End If
End Function
PBrown
Just to bring a little levity to a frustrating situation, an image sprung to mind. Do you remember the old movie "The Russians Are Coming, The Russians Are Coming", starring Alan Arkin, Joe E. Brown, etc.?
Throughout the entire movie, Joe E. Brown is trying to play Paul Revere, keeps riding his mule around and around the pen because the mule won't go through the gate so that Brown can go and warn everybody of the impending danger.
So I see you there on your Access mule, but the durn thing just won't go through the gate.
PBrown
Still puzzled why my second last code works here but not there. So I converted my Access 2000 file to Access 97, and it was still fine at this end.
I don't know what happened, but once the original file was recovered and I cut and pasted its module and on print, ect into the copy I have been working on, everything worked just fine. This has taught me that if I intend on "tweeking" a database, make a copy of it first, not just copies of the reports. That way, if I accidently delete a working report while am going through cleaning it up, the report can be recovered by the back up or copy.
As a side note, even with the keep together set to "With first Detail". I simply "touched up" the page header and sqeezed, "Continued..." in. Now it looks as if it is apart of the group header.
I have even used the items from the report (the on print, and text boxes) on a different report for the same purpose and it works like a charm. I don't like to speek too soon, but it looks as if this case is closed (Knock on Wood)! Needless to say, I am very greatful for your help in this *Mind blowing* problem, however, this is something I am sure to use in other DB's. Therefore, I am off to do some finishing touches on a few switchboards for easy user navigation.
Perhaps one time, you will have a problem that I can help with, and I am sure I will "see you around" Tek-Tips
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.