This might seem a little niche but I am encountering a weird visual issue when copying a table from excel into word, exporting the file as a PDF then printing it. I am doing all of this using Visual Basic. The reason why I do it this way is because I prepare a quote in excel and within that file, there are tables that have formulas to reference certain items. Then everything is exported to word then PDFed so I can email it to my client.
shows the end result as above. The tables were copied into word, word was exported into PDF, then printed.
shows the end result when printed directly from word. This is the result i want, however i can't send a word document to the client, it needs to be PDFed.
In , the table at the top was screen snipped (using snipping tool) and pasted in. File was converted to PDF and printed. The colours are slightly off for that table now but there are no rectangles.
Below is the code i use (in case it is relevant)
'to paste in the table, [w] variable is the word.document
Worksheets("TABLES").Range("InsuranceTable").Select
Selection.CopyPicture Appearance:=xlPrinter, Format:=xlPicture
w.Bookmarks("PreconTable").Range.Paste 'page 4
'to export the word document to PDF. I have tried both with the same result
ActiveDocument.SaveAs fPath & "\" & fName, wdFormatPDF
ActiveDocument.ExportAsFixedFormat fPath & "\" & fName, wdExportFormatPDF, True, wdExportOptimizeForPrint
Does anyone have any idea why I am getting these boxes?