+ Reply to Thread
Results 1 to 4 of 4

Trying to speed up the calculation my For Loop

  1. #1
    Registered User
    Join Date
    09-26-2009
    Location
    Mississauga, Ontario (Canada)
    MS-Off Ver
    Excel 2003
    Posts
    49

    Trying to speed up the calculation my For Loop

    I hope the title to my thread is sufficient.

    My code below checks to see if any change occurrs between Cells L5:GR12. Am I able to speed up the calculation time in anyway? I was trying to exit my for loop but that wasn't working for me.

    Please Login or Register  to view this content.

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Trying to speed up the calculation my For Loop

    In reality the Change Event is pref. to the Calculate Event because if offers Target - ie we know which cell(s) have been modified.

    From the Target we should in turn be able to deduce which cell(s) [if any] require updating via the Change Event itself.

    To determine the above we need to know the formulae contained within L5:GR12 [if any]

    Also, do you have a Change Event in place on "Audit-Jan-Jun" sheet ?

  3. #3
    Registered User
    Join Date
    09-26-2009
    Location
    Mississauga, Ontario (Canada)
    MS-Off Ver
    Excel 2003
    Posts
    49

    Re: Trying to speed up the calculation my For Loop

    Hi DonkeyOTE,

    Thanks for the reply. In range L5:GR12, no formula is present. A user would enter either a D, N, S, S10, etc in those cells. Depending on the entry the change event would color that cell.

    Further, there is no change event occurring in the "Audit~Jan-Jun" sheet. A command button enters the values in that sheet only when called upon.

    I changed my code and it works better with the exception for one thing. If I select a group of cells within L5:GR15 and hit deleted then I get a run time error 13. Any idea how to get around this one?

    Please Login or Register  to view this content.

  4. #4
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Trying to speed up the calculation my For Loop

    Without looking too deeply - perhaps try revising along the lines of:

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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