Consulting

Results 1 to 4 of 4

Thread: Maimerge last excel record

  1. #1
    VBAX Contributor
    Joined
    Sep 2007
    Posts
    119
    Location

    Maimerge last excel record

    HI there,
    I'm trying mailmerge form letter with excel data eg 6 records. But outcome turnout generating 500+ form letters. How to prevent from merge with blank record or how to code in VBA that the last record in mailmerge is the last data record in excel sheet.


    Thanks

  2. #2
    Knowledge Base Approver VBAX Guru macropod's Avatar
    Joined
    Jul 2008
    Posts
    4,435
    Location
    Open the Excel file, press Ctrl-End and that will take you to the last 'in use' cell. You'll prpbably find that row is empty. Select the entire row, then extend the selection upwards until all unused rows are selected. Press Delete then save & close the workbook. Your mailmerge should now stop at the last data row.
    Cheers
    Paul Edstein
    [Fmr MS MVP - Word]

  3. #3
    VBAX Contributor
    Joined
    Sep 2007
    Posts
    119
    Location
    Thanks Macropod. Your suggestion did improve the situation. However it still left a few blank pages. Is there a VBA to remove the blank pages while processing mail merge ?


    Thanks

  4. #4
    Knowledge Base Approver VBAX Guru macropod's Avatar
    Joined
    Jul 2008
    Posts
    4,435
    Location
    If you're still getting blank pages, that suggests you didn't clear the entire unused range. Try it again.
    Cheers
    Paul Edstein
    [Fmr MS MVP - Word]

Posting Permissions

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