LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Advice on optimizing spreadsheet

Thanks for the code, RB.

I did implement it in two versions of my model - one in which I had
explicitly copied the If statements down 10000 rows, and the other in
which I was writing the columns in the VBA subroutine itself.

The first spreadsheet was about 3.5 MB in size, and the second was about
2.5 MB. The contents include two graphs, one work sheet with about 20
rows and the main worksheet with 3 columns of 10000 rows where each row
represents the results for 1 simulation.

The results of the timing were as follows:
Explicit IF statements in the worksheet - 30094 milliseconds
Range statements in the VBA subroutine - 31047 milliseconds

When I repeated the process for 2000 simulations:
Explicit IF statements in the worksheet - 6344 milliseconds
Range statements in the VBA subroutine - 6797 milliseconds

The difference in the speed is almost negligible, since I am writing
only one column in the first case (the pre-defined formulas calculate
the other two), whereas in the second I am writing all three columns.
 
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
Lessons from optimizing a slow spreadsheet Robbro Excel Discussion (Misc queries) 2 February 25th 10 06:20 PM
Advice on Creating A Spreadsheet - HELP! NC Excel Discussion (Misc queries) 1 April 18th 08 01:16 AM
Multiple copying of a Spreadsheet advice please Dermot Excel Discussion (Misc queries) 3 July 30th 06 01:37 PM
Moving data from form to spreadsheet + VBA advice psipsi Excel Programming 0 August 30th 05 08:53 AM
Legal advice on selling Excel spreadsheet program file Gig Excel Programming 9 February 28th 05 05:07 AM


All times are GMT +1. The time now is 05:28 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"