Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple label problems

Status
Not open for further replies.

burgerman

Technical User
Sep 21, 2002
31
0
0
US
I am using the following code to print multiple labels in a report
If number = 0 Then
Me.NextRecord = True
Me.MoveLayout = False
Me.PrintSection = False
Else
If PrintCount < number Then
Me.NextRecord = False
End If
End If
Evert time I go to open the report it gives me an error message saying it can't find the number field I know it is there I just can't figure out why it is not working
any suggestions?

 
I don't see anywhere in your code that Number is defined. If this is a field in your query then you must bind it to a text box ie: txtNumber with a control source of [Number]. Your code would then read:
If Me.txtNumber = 0 Then
Me.NextRecord = True
Me.MoveLayout = False
Me.PrintSection = False
Else
If PrintCount < Me.txtNumber Then
Me.NextRecord = False
End If
End If


Duane
MS Access MVP
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top