View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
JRB JRB is offline
external usenet poster
 
Posts: 10
Default Help required to debug mailmerge procedure

I am attempting to run a mailmerge from Excel (Office 97) using the
following procedu
It doesn't work .... and I am tearing my hair out - please help before I am
completely bald
TIA

..............
Sub PrintLabels()

Dim WD As Object

Set WD = CreateObject("Word.Application")
WD.Application.DisplayAlerts = wdAlertsNone
WD.Documents.Open (ThisWorkbook.Path & "\BDayList Labels.doc")
WD.ActiveDocument.Mailmerge.Destination = wdSendToPrinter
WD.ActiveDocument.Mailmerge.Execute
WD.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges
WD.Application.DisplayAlerts = wdAlertsAll
WD.Quit SaveChanges:=wdDoNotSaveChanges
Set WD = Nothing

End Sub
..............