Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Jan 2002
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    VBA Code to print mailing labels (Access 97)

    Hi,
    I need to write VBA code, so that with a push of one button user should be able to generate/print mailing labels.
    I also need VBA code to send automatic emails....
    Help needed urgently
    Thanks,
    isha

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: VBA Code to print mailing labels (Access 97)

    Mailing labels are no more than a simple report. When in report, from main menubar, select File | Page Setup, then the Columns tab. To automatically start printing, put a command button on a form. When the wizard pops up, tell it you want to print a report.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: VBA Code to print mailing labels (Access 97)

    If you want to start the Label Wizard from a command button, use

    Run "wzmain80.mlbl_Entry", "sourcename"

    where sourcename is the name of the table or query that will serve as record source for the label report.

    If you want to print a report from a command button, see Mark's reply.

    If you want to send e-mails from Access using Outlook, look at the SendObject method of the DoCmd object in the help index, or take a look at <!post=this post, 133095>this post<!/post>.

    BTW, you write "help needed urgently". Please keep in mind that all answers on this Lounge are given by volunteers donating some of their free time to help people.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •