+ Reply to Thread
Results 1 to 2 of 2

Speed of opeartion on array vs range

  1. #1
    Forum Contributor
    Join Date
    02-05-2015
    Location
    czech
    MS-Off Ver
    2010
    Posts
    172

    Speed of opeartion on array vs range

    I have very large sheet.
    I would like to know what is generally faster method or method of first choice.

    1. using For loop like following and then operate on the range
    For i=a To b
    Range(Cells(i,i),Cells(i+a,i+b))
    Next i

    or

    2. Construct array from range, then operate on array, then put the output back to sheet
    (I know that an array has limited size in VBA.)

    Is it possible to construct master array of arrays with different dimensions?

  2. #2
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,873

    Re: Speed of opeartion on array vs range

    In most cases, Arrays are faster.
    I'd go with option 2

    If you tell what you are after, it would be easier to answer..
    Cheers!
    Deep Dave

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Can anyone tell me how to speed up this array?
    By Ppessina in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-13-2014, 06:02 PM
  2. Array looping, increase speed of array macro
    By techrcn in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 11-27-2013, 05:33 AM
  3. speed up sum if array formula with VBA??
    By jed38 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-30-2013, 01:51 PM
  4. speed up sum if array formula with VBA??
    By jed38 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-30-2013, 01:32 PM
  5. How to speed up this macro? How to use an array?
    By djvino in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-15-2012, 07:39 AM
  6. Speed up max if array
    By reddwarf in forum Excel General
    Replies: 9
    Last Post: 03-02-2011, 08:20 AM
  7. Will an Array speed this up?
    By Mase in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-04-2005, 06:53 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1