All columns of excelsheet are not fitted in same page of pdf; while converting using Excel VBA
Am trying to convert microsoft excel file with large number of columns (70+) into pdf using a Excel VBA code. In active workbook, am trying to save 'Sheet1' to PDF format at required path. I have the following code. Sub GetSaveAsFilename() Dim fileName As String fileName = Application.GetSaveAsFilename(InitialFileName:="", _ FileFilter:="PDF Files (*.pdf), *.pdf", _ Title:="Select Path and FileName to save") If fileName <> "False" Then With ActiveWorkbook .Worksheets("Sheet1").ExportAsFixedFormat Type:=xlTypePDF, fileName:= _ fileName, Quality:=xlQualityStandard, _ IncludeDocProperties:=True,