Good morning
I have an issue with a piece of code where I'm unable to fit the pdf export to one page - the end column always spills onto a second PDF page.
The code attached is part of a larger project, which all works fine, apart from this one export. I don't have much experience with page layouts within vba and googling can't get me close enough!
I have an issue with a piece of code where I'm unable to fit the pdf export to one page - the end column always spills onto a second PDF page.
The code attached is part of a larger project, which all works fine, apart from this one export. I don't have much experience with page layouts within vba and googling can't get me close enough!
VBA Code:
Range("a1:s" & lrow2).Copy
Set WBCIR = Workbooks.Add
Range("a1").PasteSpecial (xlPasteValues)
Range("A:V").EntireColumn.AutoFit
ActiveSheet.PageSetup.PrintArea = "a1:s10"
Range("A:A").EntireColumn.Delete
WBCIR.SaveAs Filename:=SaveFP & CustomerID & " " & CaseNumber & ".xlsx"
Selection.ExportAsFixedFormat Type:=xlTypePDF, Filename:=SaveFP & CustomerID & " " & CaseNumber & ".pdf"
WBCIR.Close