Print a mailing label for a single record

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

What I'm trying to do is print a single mailing address label from a data
entry input screen. Is there any way to put a button on the form that says
"Print Label" and it will print a mailing label with the customers name and
address? All I'm finding in my search so far is how to print sheets of
mailing labels from the entire database or a query - I cannot find info on
how to print just 1 shipping label. Is this possible?
 
You can send the current reocrd to a report as follows:

me.Refresh

docmd.OpenReport "YourReprotName",acViewPreview,,"id = " & me.id
 
Albert I have the same similar problem. I have created a label report but
would also like to print what ever I want. Can you be a bit more explanitory
in your code. Where do I put the code. I am a frequent user of Access but I
really do not know where to put code. Can you give me detailed instructions.
Much appreciated.
Lee
 
Albert I have the same similar problem and would like only to print whatever
label I desire. Can you explain your code you posted previously. Not sure
where to apply it. Thank you in advance.

Lee
 
Just place the code behind a button you put on the form.

You can put a button on the form...and then select the on-click event for
the button in the properties sheet (event tab). When the little [...] button
appears when you select the on click event..click on that...and select
"code".

I do outline the series of steps to add a button to your form (however, the
following example is somewhat differnt.....it will give you the idea:

Scroll down to the part called:

Adding a command button to your form....

http://www.attcanada.net/~kallal.msn/wordmerge/Details.htm
 
Hello ALbert. In your last email you made a comment of making a command
button in my form. I created a form called customer info labels with
appropriate info and saved it. I also created a report called
customerlabels. I created a command button in my customer info labels form
and added the code as you suggested. I also edited the code line to reflect
my customerlabel report. When I click on the button in my form nothing
happens.

What do you think.
Lee
 
Albert I finally got the chance to create the Mailing labels command botton
on a form. Which points to my report called LabelsCustomerInvoices I put
the code in behind the button in the onclick event. I also changed the
YourReportName to LabelsCustomerInvoices. I get a error message in the
latter part of the code the me.id not sure what this means. Should I be
putting something in this area of the code exclusive to my form??
Thanks for all your help up to so far...
Lee
 
Albert here is a bit more info. This is what my event looks like. WHat do
you think?

Private Sub Command89_Click()
On Error GoTo Err_Command89_Click

stDocName = "LabelsCustomerInvoices"

Me.Refresh

DoCmd.OpenReport "LabelsCustomerInvoices", acViewPreview, , "id = " & Me.id
 
Back
Top