Wee Kuang
Board Regular
- Joined
- Sep 15, 2011
- Messages
- 59
Dear all,
I'm currently devising this code to do a automatic setting of print area. The statement goes like this.
LastRow = Cells.SpecialCells(xlCellTypeLastCell).Row
ActiveSheet.PageSetup.PrintArea = "$A$1:$X$" & LastRow + 3
I thought it was alright but when I run the code and check the print area. I had like 7 more pages without any data inside these pages. Can anyone point to me if my code is correct?
Any help will more warmly welcome.
I'm currently devising this code to do a automatic setting of print area. The statement goes like this.
LastRow = Cells.SpecialCells(xlCellTypeLastCell).Row
ActiveSheet.PageSetup.PrintArea = "$A$1:$X$" & LastRow + 3
I thought it was alright but when I run the code and check the print area. I had like 7 more pages without any data inside these pages. Can anyone point to me if my code is correct?
Any help will more warmly welcome.