Thread: [Solved] Updating tables in Word
View Single Post
 
Old 04-11-2025, 08:06 AM
BigMac'ro BigMac'ro is offline Windows 10 Office 2016
Novice
 
Join Date: Feb 2025
Posts: 9
BigMac'ro is on a distinguished road
Default

Thank you for the quick answer! Using early binding is for sure better, and I even already had the library references checked. I now modified the variable declarations:
Code:
Dim xlApp As Excel.Application
    Dim xlRefWB As Excel.Workbook
    Dim xlDataWB As Excel.Workbook
    Dim xlSheet As Excel.Worksheet
    Dim chartObj As Excel.chartObject
    Dim i As Long, lastRow As Long
    Dim wordBookmark As String
    Dim filePath As String, sheetName As String, rangeOrChart As String
    Dim bmRange As Word.Range
But when using
Code:
chartObj.ChartArea.Copy
, runtime error 438 occurs
I'll leave the screen a bit and see if I can find a solution later...
Reply With Quote