![]() |
Print Area
What would be the code for setting the print area equal to the currently selected range on a sheet (i.e. not just e.g. "a1:d4", but something that changes? -- wammer ------------------------------------------------------------------------ wammer's Profile: http://www.excelforum.com/member.php...o&userid=12452 View this thread: http://www.excelforum.com/showthread...hreadid=401350 |
Print Area
Per the (verbatim) example in VBA help:
ActiveSheet.PageSetup.PrintArea = ActiveCell.CurrentRegion.Address -- George Nicholson Remove 'Junk' from return address. "wammer" wrote in message ... What would be the code for setting the print area equal to the currently selected range on a sheet (i.e. not just e.g. "a1:d4", but something that changes? -- wammer ------------------------------------------------------------------------ wammer's Profile: http://www.excelforum.com/member.php...o&userid=12452 View this thread: http://www.excelforum.com/showthread...hreadid=401350 |
Print Area
Instead of fiddling with the printrange, maybe just printing the selection would
be enough: selection.printout (may not apply to what you really want to do, though.) wammer wrote: What would be the code for setting the print area equal to the currently selected range on a sheet (i.e. not just e.g. "a1:d4", but something that changes? -- wammer ------------------------------------------------------------------------ wammer's Profile: http://www.excelforum.com/member.php...o&userid=12452 View this thread: http://www.excelforum.com/showthread...hreadid=401350 -- Dave Peterson |
All times are GMT +1. The time now is 05:30 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com