| 1:2:
 3:
 4:
 5:
 6:
 7:
 8:
 9:
 10:
 11:
 12:
 13:
 14:
 15:
 16:
 17:
 18:
 19:
 20:
 21:
 22:
 23:
 24:
 25:
 26:
 27:
 28:
 29:
 30:
 31:
 32:
 33:
 34:
 35:
 36:
 37:
 38:
 39:
 40:
 41:
 42:
 43:
 
 | uses word_TLB ;  { Typbibliothek }
 procedure TDBRTFReport.PrintReport ;
 var
 W : variant ;
 begin
 { Word öffnen und Dokument laden }
 W := CreateOleObject ('Word.Application') ;
 W.Visible := false ;
 W.Documents.open (FReport, False, True, False, '', '', False, '', '',wdOpenFormatAuto) ;
 
 { Drucken }
 W.ActivePrinter := FPrinter.Printername ;
 W.Options.UpdateFieldsAtPrint := False ;
 W.Options.UpdateLinksAtPrint := False ;
 W.Options.DefaultTray := FPrinter.Schacht ;   { Fachausgabe angeben }
 W.Options.PrintBackground := True ;
 W.Options.PrintProperties := False ;
 W.Options.PrintFieldCodes := False ;
 W.Options.PrintComments := False ;
 W.Options.PrintHiddenText := False ;
 W.Options.PrintDrawingObjects := True ;
 W.Options.PrintDraft := False ;
 W.Options.PrintReverse := False ;
 W.Options.MapPaperSize := True ;
 
 W.PrintOut (FileName:='',
 Range:=wdPrintAllDocument,
 Item:= wdPrintDocumentContent,
 Copies:=FPrinter.Kopien,            { Anzahl der kopien }
 Pages:=FPrinter.Seiten,
 PageType:=wdPrintAllPages,
 Collate:=True,
 Background:=false,  { WICHTIG !! }
 PrintToFile:=False,
 PrintZoomColumn:=0,
 PrintZoomRow:=0,
 PrintZoomPaperWidth:=0,
 PrintZoomPaperHeight:=0) ;
 
 W.Activedocument.Close (SaveChanges := false) ;
 W.Quit ;
 end;
 |