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 » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Printing Labels but designating which label on sheet to start prin



 
 
Thread Tools Display Modes
  #1  
Old August 11th, 2009, 07:10 PM posted to microsoft.public.access.reports
chris
external usenet poster
 
Posts: 2,039
Default Printing Labels but designating which label on sheet to start prin

I have a database with records that need to be extracted and printed on
labels. I have a report set up that is perfect for a full sheet of labels.
However, most of these records do not use an entire sheet leaving many unused
labels. Is there a way to designate which row and column to start printing
on a sheet of labels so that we can utilize the full sheet?
Thanks,
Chris

  #2  
Old August 11th, 2009, 09:50 PM posted to microsoft.public.access.reports
fredg
external usenet poster
 
Posts: 4,386
Default Printing Labels but designating which label on sheet to start prin

On Tue, 11 Aug 2009 11:10:01 -0700, Chris wrote:

I have a database with records that need to be extracted and printed on
labels. I have a report set up that is perfect for a full sheet of labels.
However, most of these records do not use an entire sheet leaving many unused
labels. Is there a way to designate which row and column to start printing
on a sheet of labels so that we can utilize the full sheet?
Thanks,
Chris


First create a label report that prints a full sheet of labels.
Then add a Report Header.
Add 2 unbound controls to the Header.
Name one "SkipControl"
Leave it's control source blank.

Name the other control "SkipCounter"
Set it's control source to:
=[Skip how many?]

Then code the report's Detail Print event¡K

Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
If PrintCount = [SkipCounter] And [SkipControl] = "Skip" Then
Me.NextRecord = False ' Skip missing labels on sheet
Me.PrintSection = False
Else
[SkipControl] = "No" ' Print labels
Me.PrintSection = True
Me.NextRecord = True
End If

End Sub

And code the Report Header's Format event¡K

Private Sub ReportHeader_Format(Cancel As Integer, FormatCount As
Integer)
[SkipControl] = "Skip"
Cancel = True
End Sub

Run the label report. Enter the number of label positions you wish to
skip.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
  #3  
Old August 11th, 2009, 11:22 PM posted to microsoft.public.access.reports
chris
external usenet poster
 
Posts: 2,039
Default Printing Labels but designating which label on sheet to start

Fred,
Thank you for the detailed response. I followed your instructions but am
not getting the results I was hoping for. I am prompted to enter the number
of skips but it still prints starting from the first label at the top. In
addition, it shows the number I entered in the report header. Any hints as
where I went wrong would be very appreciated.
Thanks,
Chris


"fredg" wrote:

On Tue, 11 Aug 2009 11:10:01 -0700, Chris wrote:

I have a database with records that need to be extracted and printed on
labels. I have a report set up that is perfect for a full sheet of labels.
However, most of these records do not use an entire sheet leaving many unused
labels. Is there a way to designate which row and column to start printing
on a sheet of labels so that we can utilize the full sheet?
Thanks,
Chris


First create a label report that prints a full sheet of labels.
Then add a Report Header.
Add 2 unbound controls to the Header.
Name one "SkipControl"
Leave it's control source blank.

Name the other control "SkipCounter"
Set it's control source to:
=[Skip how many?]

Then code the report's Detail Print event…

Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
If PrintCount = [SkipCounter] And [SkipControl] = "Skip" Then
Me.NextRecord = False ' Skip missing labels on sheet
Me.PrintSection = False
Else
[SkipControl] = "No" ' Print labels
Me.PrintSection = True
Me.NextRecord = True
End If

End Sub

And code the Report Header's Format event…

Private Sub ReportHeader_Format(Cancel As Integer, FormatCount As
Integer)
[SkipControl] = "Skip"
Cancel = True
End Sub

Run the label report. Enter the number of label positions you wish to
skip.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail

  #4  
Old August 11th, 2009, 11:40 PM posted to microsoft.public.access.reports
fredg
external usenet poster
 
Posts: 4,386
Default Printing Labels but designating which label on sheet to start

On Tue, 11 Aug 2009 15:22:01 -0700, Chris wrote:

Fred,
Thank you for the detailed response. I followed your instructions but am
not getting the results I was hoping for. I am prompted to enter the number
of skips but it still prints starting from the first label at the top. In
addition, it shows the number I entered in the report header. Any hints as
where I went wrong would be very appreciated.
Thanks,
Chris

"fredg" wrote:

On Tue, 11 Aug 2009 11:10:01 -0700, Chris wrote:

I have a database with records that need to be extracted and printed on
labels. I have a report set up that is perfect for a full sheet of labels.
However, most of these records do not use an entire sheet leaving many unused
labels. Is there a way to designate which row and column to start printing
on a sheet of labels so that we can utilize the full sheet?
Thanks,
Chris


First create a label report that prints a full sheet of labels.
Then add a Report Header.
Add 2 unbound controls to the Header.
Name one "SkipControl"
Leave it's control source blank.

Name the other control "SkipCounter"
Set it's control source to:
=[Skip how many?]

Then code the report's Detail Print event¡K

Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
If PrintCount = [SkipCounter] And [SkipControl] = "Skip" Then
Me.NextRecord = False ' Skip missing labels on sheet
Me.PrintSection = False
Else
[SkipControl] = "No" ' Print labels
Me.PrintSection = True
Me.NextRecord = True
End If

End Sub

And code the Report Header's Format event¡K

Private Sub ReportHeader_Format(Cancel As Integer, FormatCount As
Integer)
[SkipControl] = "Skip"
Cancel = True
End Sub

Run the label report. Enter the number of label positions you wish to
skip.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail


I believe you miss-understood the instructions.

1) Add 1 unbound control to the Report Header.
Set it's control source to
="Skip"
Name this control "SkipControl"

Add another unbound control.
Set it's control source to:

2) =[Skip how many?]
Literally... exactly as I have written it. Do not enter a number
value.
Name this control "SkipCounter".

3) If it shows a value in the report header, you did not code the
Report Header Format event as I suggested.
The Cancel = True hides the Report Header so you should not see
anything in it.

--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
  #5  
Old August 12th, 2009, 03:36 AM posted to microsoft.public.access.reports
Allen Browne
external usenet poster
 
Posts: 11,706
Default Printing Labels but designating which label on sheet to start

Fred, I'm wondering if Chris is using Access 2007, and opening it in Report
view (or even Layout view.)

The section events don't fire in these views, and so the code would not
work.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.


"fredg" wrote in message
.. .
On Tue, 11 Aug 2009 15:22:01 -0700, Chris wrote:

Fred,
Thank you for the detailed response. I followed your instructions but am
not getting the results I was hoping for. I am prompted to enter the
number
of skips but it still prints starting from the first label at the top.
In
addition, it shows the number I entered in the report header. Any hints
as
where I went wrong would be very appreciated.
Thanks,
Chris

"fredg" wrote:

On Tue, 11 Aug 2009 11:10:01 -0700, Chris wrote:

I have a database with records that need to be extracted and printed on
labels. I have a report set up that is perfect for a full sheet of
labels.
However, most of these records do not use an entire sheet leaving many
unused
labels. Is there a way to designate which row and column to start
printing
on a sheet of labels so that we can utilize the full sheet?
Thanks,
Chris

First create a label report that prints a full sheet of labels.
Then add a Report Header.
Add 2 unbound controls to the Header.
Name one "SkipControl"
Leave it's control source blank.

Name the other control "SkipCounter"
Set it's control source to:
=[Skip how many?]

Then code the report's Detail Print event¡K

Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
If PrintCount = [SkipCounter] And [SkipControl] = "Skip" Then
Me.NextRecord = False ' Skip missing labels on sheet
Me.PrintSection = False
Else
[SkipControl] = "No" ' Print labels
Me.PrintSection = True
Me.NextRecord = True
End If

End Sub

And code the Report Header's Format event¡K

Private Sub ReportHeader_Format(Cancel As Integer, FormatCount As
Integer)
[SkipControl] = "Skip"
Cancel = True
End Sub

Run the label report. Enter the number of label positions you wish to
skip.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail


I believe you miss-understood the instructions.

1) Add 1 unbound control to the Report Header.
Set it's control source to
="Skip"
Name this control "SkipControl"

Add another unbound control.
Set it's control source to:

2) =[Skip how many?]
Literally... exactly as I have written it. Do not enter a number
value.
Name this control "SkipCounter".

3) If it shows a value in the report header, you did not code the
Report Header Format event as I suggested.
The Cancel = True hides the Report Header so you should not see
anything in it.

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


  #6  
Old August 12th, 2009, 06:01 AM posted to microsoft.public.access.reports
fredg
external usenet poster
 
Posts: 4,386
Default Printing Labels but designating which label on sheet to start

On Wed, 12 Aug 2009 10:36:47 +0800, Allen Browne wrote:

Fred, I'm wondering if Chris is using Access 2007, and opening it in Report
view (or even Layout view.)

The section events don't fire in these views, and so the code would not
work.


Thanks for calling that to our attention, Alan.
I don't use Access 2007 so I have no idea of the differences between
it and the previous versions of Access.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
 




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 11:58 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.