Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete columns and set print area
Does anyone have a macro that can delete a pre-set series of columns an
then set the page setup to print 1 page wide in Landscape format pleas ? I.e. Delete columns b,c,d and f, then page setup to print 1 page wid in landscape format. I have a daily report which contains a number of columns which I don need and I delete them normally before printing the report off to fi to at least 1 page wide. The number of pages high is dependant on ho long the report is -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete columns and set print area
Sub test()
Range("B:B,C:C,D:D,F:F").Delete xlShiftToLeft With ActiveSheet.PageSetup .Orientation = xlLandscape .Zoom = False .FitToPagesWide = 1 .FitToPagesTall = 1 End With End Sub -- Rob van Gelder - http://www.vangelder.co.nz/excel "twaccess " wrote in message ... Does anyone have a macro that can delete a pre-set series of columns and then set the page setup to print 1 page wide in Landscape format please ? I.e. Delete columns b,c,d and f, then page setup to print 1 page wide in landscape format. I have a daily report which contains a number of columns which I dont need and I delete them normally before printing the report off to fit to at least 1 page wide. The number of pages high is dependant on how long the report is. --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete columns and set print area
Thanks very much for this Rob. It is much appreciated and will make m
daily life easier. There is another bit of finesse though. What would the coding be t autofit the column widths to the text as well please ? Thanks T -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
delete unused columns and grey out the rest area | Excel Worksheet Functions | |||
Can you delete all hidden columns in an area in one move? | Excel Discussion (Misc queries) | |||
Pivot Table macro to set print area and print details of drill down data | Excel Discussion (Misc queries) | |||
Create a print macro that would automatically select print area? | Excel Worksheet Functions | |||
Identify and Delete all Rows and Columns NOT in Print Area | Excel Programming |