

- #Excel different margins on first page how to#
- #Excel different margins on first page mac os#
- #Excel different margins on first page code#
- #Excel different margins on first page trial#
LeftMargin = Application.InchesToPoints(1.5) CenterHeader = "Page # " & lNum & " of " & lTotal BottomMargin = Application.InchesToPoints(0.4) TopMargin = Application.InchesToPoints(0.4) RightMargin = Application.InchesToPoints(1.5) LeftMargin = Application.InchesToPoints(0.2) I have no idea why 54 = 1.905 cm, or how this works.Įven so, I still can’t get the pages to print with different margin on the odd and even pages.
#Excel different margins on first page trial#
After considerable trial and error, I discovered that by making the value 54, I finished up with a margin of 1.905 cm (I did this by running the VBA and then checking the margin in Layout/Margins after each trial). I set the print area as normal in File/Print/Set Print AreaĪs you can see, I gave a value only to the Left Margin on the odd page (the critical margin measurement), and only to the Right Margin on the even page (the critical margin measurement).Īlthough I set the margin to 1.905 cm, the result was different.
#Excel different margins on first page code#
I realise the lines of code for the Top, Bottom, Header and Footer margin are circular, and probably unnecessary, but this worked for those margins, so I left them. Cells.Find(What:="*", After:=, SearchDirection:=xlPrevious) Although I found one solution (posted by Administrator Dave Hawley in answer to a post from Mikeburg, 15 June 2006), I have been unable to get that to work. I am not very experienced with VBA, and have searched exhaustively for a solution in the posts here and elsewhere before posting this. I am printing on both sides of the paper with a duplex printer and need the left margin greater than the right margin to allow for the pages to be bound into a long edge, left-side-bound booklet. This video lesson is from our complete Excel tutorial, titled “ Mastering Excel Made Easy v.2019 and 365.I am trying to print different margins for the odd pages, and the even pages, from an Excel document with 50+ pages.
#Excel different margins on first page how to#
The following video lesson, titled “ Setting Margins,” shows how to set margins in Excel worksheets.

Then click the “Margins” tab within the “Page Setup” dialog box. Then click the “Page Setup” dialog box button in the lower-right corner of the “Page Setup” button group. If you print the spreadsheet from the File menu, the preview will only display the selected information. To open the “Page Setup” dialog box, click the “Page Layout” tab in the Ribbon. Click on Set Print Area, and Excel will show you a preview with a dotted line around your selected entries. To set margins in Excel worksheets before printing, open the “Page Setup” dialog box.
#Excel different margins on first page mac os#
