# Paste Excel chart into Word using VBA



## MacroAlan (Aug 28, 2017)

It seemed like it should be so easy. I'm creating a bunch of data from Access and sending to Excel and then creating a bunch of Charts.

Charts look good. As each is created, I want to copy it and paste into a Word document.


```
Set WDapp = CreateObject("Word.Application")
    WDapp.Documents.Open RptPath & RptName & WDdate
'Translates to “History Data_20170828.docx”
'------------------ other stuff

    For Z = 1 To ActiveSheet.ChartObjects.Count
        With ActiveSheet.ChartObjects(Z)
            .Left = Range("K" & LftRow).Left
            .Top = Range("K" & LftRow).Top
            .Width = 800
            .Height = 525
            .Copy
        End With
        WDapp.activedocument.PasteSpecial Link:=False, DataType:=wdpastetext, Placement:=wdinline, displayasicon:=False               'This line fails
```

It's been years since I've done any Word programming in VBA.


----------



## Macropod (Aug 28, 2017)

You need to tell Word where to paste the chart - and use an appropriate paste format (DataType). For example:
WDapp.ActiveDocument.Range.Characters.Last.PasteSpecial Link:=False, DataType:=wdPasteEnhancedMetafile, Placement:=wdInLine, DisplayAsIcon:=False
Using:
.Range.Characters.Last
tells Word to paste the chart at the very end of the document.


----------

