VBA was working fine. now adding blank pages

mrpwagner

New Member
Joined
Jul 17, 2016
Messages
22
Through this page I received excellent assistance getting a VBA to print the pages from my call schedule.

I copy forward each month and make changes and it works great!!!!

Until this month when it started adding blank pages. In particular 4 blank pages with the appropriate footer after the unavailability sheet.

WHY?

I have run the macro from previous months where the original does not have the extra 4 pages......and am now getting the additional four pages.

Any assistance would be welcome.






Private Sub October2017FullPrintout_Click()
With Application
.ScreenUpdating = False
.DisplayAlerts = False
End With


Sheets("Assignments").Select
With ActiveSheet.PageSetup
.Printarea = "$C$286:$Z$316"
.Orientation = xlLandscape
End With


Sheets("Unavailability").Select
With ActiveSheet.PageSetup
.Printarea = "$C$286:$BB$408"
.Orientation = xlLandscape
End With


Sheets("Yearly Calculations 2017").Select
With ActiveSheet.PageSetup
.Printarea = "$a$9:$ar$34"
.Orientation = xlLandscape
End With


Sheets(Array("2017.10 Printout", "2017.10 Calculations", "Assignments", "Unavailability", "Yearly Calculations 2017")).PrintOut


With Application
.ScreenUpdating = True
.DisplayAlerts = True
End With
End Sub
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Figured it out!!!!

Expanded some things so there was an edge of the selected cells that was not within the page margins. Once I had adjusted the margins everything printed on the requisite number of pages. I knew it would be easy.....just wasn't seeing it.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,178
Members
453,021
Latest member
Justyna P

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