Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Programmatically set print area in Excel
I have a spreadsheet that contains accuracy information for projects
based. Column A is the date column and columns B-BF are for reporting pass/fail results for several workgroups. The top 3 rows contain the sums of pass/fail, the percent of pass, and the workgroup name. I would like to be able to set the print area to programmatically decide the last 10 working days worth of information to print. Any assistance would be appreciated. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Programmatically set print area in Excel
If the working days/dates in Column A in ascending order:
Sub SetPrintArea() Dim Lastrow As Long Lastrow = Cells(Rows.Count, 1).End(xlUp).Row Cells(Lastrow - 9, 1).Resize(10, 58).Select ActiveSheet.PageSetup.PrintArea = Selection End Sub msunder wrote: I have a spreadsheet that contains accuracy information for projects based. Column A is the date column and columns B-BF are for reporting pass/fail results for several workgroups. The top 3 rows contain the sums of pass/fail, the percent of pass, and the workgroup name. I would like to be able to set the print area to programmatically decide the last 10 working days worth of information to print. Any assistance would be appreciated. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
set area in excel not giving me option to set print area? | Excel Discussion (Misc queries) | |||
split print area in excel - One Page Print | Excel Worksheet Functions | |||
File, print area, clear area, is not working | New Users to Excel | |||
Macro - Set Print Area for Changing Data Area | Excel Programming | |||
How do you turn off a print area for a page? (no print area) | Excel Discussion (Misc queries) |