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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Printing forms in access

Status
Not open for further replies.

p3ngu1n1337

IS-IT--Management
Feb 12, 2004
9
CA
Hi all,
First of all........AHHHHHHHHHHHHHHHHHH!
I have been working on this issue for days now and can't seem to get the result I am trying for.
I have a three part preprinted form I need to print on.
The three parts are all identical (it's an invoice).
I have created the form in access to print data only and that works great. The data is all lined up and prints in the boxes perfectly. I use another form, the main one, to enter all of the paticulars for all clients. On the main form I created a button that will print the invoice form with the data I need from the main form. This workss great except for one thing.....it prints the same data in all three invoices on the page. What I want to be able to do is find a way to print three different invoice on the the invoice form since each pre printed form contains 3 identical invoices.
I hope this makes sense.
I guess and option would be if there is some way to print all recently created invoice at once after all the info has been entered. Again the trick is to be able to have 3 different sets of identical info on one form.
Please help if you can.
Thanx in advance
 
I'm not sure what your exact situation is after reading your note. Sounds like it would take some time to go through it.
I've used form printing automation somewhat. My basic approach is 1) I print one record per form printout. This means all the data for one unique record is contained in the same record and then the form data is filled from the record: one record per form. 2) to automate printing of multiple form printouts, i.e. multiple records, I use a looping routine and execute a new print for each record. In this way, I'm not trying to print a bunch of records with one print command (to do so, the forms do not line up right). Here's an example of a routine that may give you some ideas. It used an array to hold the record numbers to be printed and then it prints each record:
Public Function PrintRec()
'Allows user to print multiple records of Transmittal Form Printing in or out of sequence
Dim Recd(1 To 50) As Integer, I As Integer, I2 As Integer, Dim Answer As String
Answer = "First Try"
I = 1
Do 'Until Answer = ""
Answer = InputBox("Next record # to print? OK or Cancel if done.", "Records to Print")
If Answer = "" Then
Exit Do
Else
Recd(I) = CInt(Answer)
I = I + 1
End If
Loop
If I > 1 Then
For I2 = 1 To I - 1
DoCmd.PrintOut acPages, Recd(I2), Recd(I2)
Next
Else
MsgBox "No records will be printed."
End If
End Function

Jeff
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top