View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Rob van Gelder[_4_] Rob van Gelder[_4_] is offline
external usenet poster
 
Posts: 1,236
Default 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/