View Single Post
  #5  
Old November 25th, 2005, 05:04 AM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Print to Header, Not Detail

On Thu, 24 Nov 2005 14:12:01 -0700, bw wrote:

Thanks for the reply, Fred
I'm getting an error:
"Microsoft Access can't find the macro 'Me![Show]=1."

I'm not sure were, or how you wanted me to enter your code. I have the
following procedure, which is producing the error:
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Cancel = Me![Show] = 1
Me![Show] = 2
End Sub

Can you please explain in further detail?
Thanks,
Bernie

"fredg" wrote in message
.. .
On Wed, 23 Nov 2005 17:47:35 -0700, bw wrote:

I'd like to print the first record of a group to the Page or Group
header,
but not print that record again in the detail section.

How's it done?
Thanks,
Bernie


Place your controls in the Page header.

Add an unbound control to the detail section.
Name it Show.
You can make it not visible.

Code the Page Header Format event:
Me![Show] = 1

Code the Detail Format event:
Cancel = Me![Show] = 1
Me![Show] = 2

That should do it for you.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail


Did you add an unbound control to the Detail section of your report?
Did you name it "Show", as I wrote in my first reply?

Add an unbound control to the detail section.
Name it Show.
You can make it not visible.

--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail