Printing in a particular label space

C

Chegu Tom

I need to print labels from an access report. I only need to print one or
two at a time leaving most of the sheet of labels unused.

I would like to put a partially used label sheet into the printer and tell
the report to skip the first 'x' labels and print on label x+1 thus using
the next avaialble label on the sheet. (x can be read from a control on
the form that generates the report)

Is this something in the On Format event?

Thanks for any tips


Tom
 
F

fredg

I need to print labels from an access report. I only need to print one or
two at a time leaving most of the sheet of labels unused.

I would like to put a partially used label sheet into the printer and tell
the report to skip the first 'x' labels and print on label x+1 thus using
the next avaialble label on the sheet. (x can be read from a control on
the form that generates the report)

Is this something in the On Format event?

Thanks for any tips

Tom

First make sure your label report is properly printing a full sheet of
labels.

Then add a Report Header to your label report.
Add 2 text boxes to the Header.
1) Name one SkipControl
Leave it's control source unbound

2) Name the other SkipCounter
Set it control Source to =[Skip How Many?]

Now code the Report Header Format event as below:

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

Next code the Detail OnPrint event:

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

End Sub
=====

When you are ready to run the label report, it will ask how many to
skip.
Then it will run the report.
 
C

Chegu Tom

Thanks again fred. That work just like I wanted
Tom


fredg said:
I need to print labels from an access report. I only need to print one
or
two at a time leaving most of the sheet of labels unused.

I would like to put a partially used label sheet into the printer and
tell
the report to skip the first 'x' labels and print on label x+1 thus
using
the next avaialble label on the sheet. (x can be read from a control on
the form that generates the report)

Is this something in the On Format event?

Thanks for any tips

Tom

First make sure your label report is properly printing a full sheet of
labels.

Then add a Report Header to your label report.
Add 2 text boxes to the Header.
1) Name one SkipControl
Leave it's control source unbound

2) Name the other SkipCounter
Set it control Source to =[Skip How Many?]

Now code the Report Header Format event as below:

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

Next code the Detail OnPrint event:

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

End Sub
=====

When you are ready to run the label report, it will ask how many to
skip.
Then it will run the report.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top