Excel to Word Automation - Help wtih scaling, fitting to page

jordanjv

New Member
Joined
Mar 22, 2017
Messages
1
I have created a macro to copy and paste a range of cells from Excel into a Word document. Everything seems to be copying correctly, however the information is not scaled to fit a single page in Word (it does fit a single page in Excel.) The pasted data is much larger in Word. How can I scale the pasted information to fit a single page in Word?

Here is my current code (at some point I had it figured out but somehow change it...)

Sub Email()
Range("A4:G48").Select
Selection.Copy
Set appWD = CreateObject("Word.Application.8")
appWD.Visible = True
appWD.Documents.Add.Content.PasteSpecial Link:=False, DataType:=wdPicture
With appWD.ActiveDocument.PageSetup
.TopMargin = appWD.InchesToPoints(0.4)
.BottomMargin = appWD.InchesToPoints(0.4)
.LeftMargin = appWD.InchesToPoints(0.4)
.RightMargin = appWD.InchesToPoints(0.4)
End With
End Sub
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN

Forum statistics

Threads
1,213,494
Messages
6,113,974
Members
448,537
Latest member
Et_Cetera

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top