Faster Pagesetup in Excel VBA using xlDialogPageSetup

P

Philip

Hi,

I have had some success doing a fast PageSetup in MS Excel using the
xlDialogPageSetup (from Colo's Excel Junk Room at
http://puremis.net/excel/code/039.shtml) and the XL4 Macro PAGE.SETUP.

I have even got SET.PRINT.AREA and SET.PRINT.TITLES to work, which is again
better than using Activesheet.pagesetup.

But is there a way to use the xlDialogPageSetup
(Application.Dialogs(xlDialogPageSetup).show...) method to set the PrintArea
and the PrintTtitle rows?

BTW - in case anyone needs it, the original MS Help file for all of these
Excel 4 Macro functions is on the MS Website:
http://support.microsoft.com/default.aspx?scid=kb;en-us;128185

thanks
Philip
 
J

Jon Peltier

You can set Print Area and Print Titles very quickly using this:

ActiveSheet.Range("A1:D10").Name = "'" & ActiveSheet.Name & "'!Print_Area"
ActiveSheet.Range("1:2,A:B").Name = "'" & ActiveSheet.Name &
"'!Print_Titles"

- Jon
 
P

Philip

Thanks Jon... that'll do nicely!

Jon Peltier said:
You can set Print Area and Print Titles very quickly using this:

ActiveSheet.Range("A1:D10").Name = "'" & ActiveSheet.Name & "'!Print_Area"
ActiveSheet.Range("1:2,A:B").Name = "'" & ActiveSheet.Name &
"'!Print_Titles"

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
Peltier Technical Services, Inc. - http://PeltierTech.com
_______
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top