LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 186
Default Faster Way to Execute Code

Hi,
I have a couple of macros in which I create many (100-200) worksheets in one
workbook. As part of the formatting I have a loop with code like that shown
below to establish the page set up in each sheet. When I run this macro, it
looks to me like this part of the code inceases the macro run time
considerably. Is there any way to shorten this time?

With ActiveSheet.PageSetup
.PrintTitleRows = "$1:$3"
.PrintArea = "$A$1:$I" & NumRowsActSheet
.CenterHeader = "&""Arial,Bold""&12F820 Report for " & ActiveSheet.Name
.LeftFooter = "&P of &N"
.RightFooter = "&D &T"
.LeftMargin = Application.InchesToPoints(0)
.RightMargin = Application.InchesToPoints(0)
.PrintGridlines = True
.CenterHorizontally = True
.Orientation = xlLandscape
.Zoom = 100
End With

TIA.
--
Ken Hudson
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Faster way to code this jhahes[_63_] Excel Programming 3 July 6th 06 05:08 PM
Can faster CPU+larger/faster RAM significantly speed up recalulati jmk_li Excel Discussion (Misc queries) 2 September 28th 05 10:24 AM
Which is faster code... Marcotte A Excel Programming 2 October 23rd 04 01:03 AM
Lag functions or faster code Frank Fuller Excel Programming 1 October 16th 03 05:17 PM
Could this code be faster? ste mac Excel Programming 2 August 27th 03 12:59 PM


All times are GMT +1. The time now is 09:46 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"