Thread: Set Print Area
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default Set Print Area


Instead of using a macro why not just modify the Print_Area defined name to
=offset($a$1,0,0,counta($a:$a),3)
where it will now self adjust. Don't delete row 1

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Porky79" wrote in message
...
Hi - I have recorded a simple macro to set a print area on a
worksheet.

Range("A1:C52").Select
ActiveSheet.PageSetup.PrintArea = "$A$1:$C$52"

Rows will always remain constant (1:52) but the columns vary (columns
are added from D onwards as data is collected). I want to try and edit
it so that it will set the range automatically. Can I use the OFFSET
function to automatically set this up?

Any help will be much appreciated

thanks

Paul