+ Reply to Thread
Results 1 to 9 of 9

Macron running extremely slow after update to Excel 2016

  1. #1
    Forum Contributor
    Join Date
    11-20-2012
    Location
    stockholm
    MS-Off Ver
    Excel 2010
    Posts
    123

    Macron running extremely slow after update to Excel 2016

    Hi

    I have previously run Excel 2010. After update to Excel 2016 macros runinng extremly slow. Does any one know why?

    Below is my code. Its runs thousands of rows of input data through a recipe database and throws out the components in a output sheet. in Excel 2010 it run through 100 rows/s in Excel 2016 the same number is 2 rows/s. The input data is 18000 rows. So macro time has increased from 3 minutes to 2,5 hours.

    Please Login or Register  to view this content.
    I have searched the internet, looking for people with the same kind of problem - and there is but I find no solutions?

    Any ideas??

    Many many thanks
    //Martin
    Last edited by masben; 03-08-2016 at 03:22 PM.

  2. #2
    Forum Contributor kalbasiatka's Avatar
    Join Date
    02-27-2016
    Location
    Brest, Belarus
    MS-Off Ver
    2021
    Posts
    224

    Re: Macron running extremely slow after update to Excel 2016

    not use "select" and move on arrays
    To do it for me and help me it is 2 different things!
    Sorry for my english, blame Google translator

  3. #3
    Forum Contributor
    Join Date
    11-20-2012
    Location
    stockholm
    MS-Off Ver
    Excel 2010
    Posts
    123

    Re: Macron running extremely slow after update to Excel 2016

    Quote Originally Posted by kalbasiatka View Post
    not use "select" and move on arrays
    Thanks for youre reply!

    How do you mean?

    All the best,
    Martin

  4. #4
    Valued Forum Contributor
    Join Date
    01-03-2016
    Location
    Conwy, Wales
    MS-Off Ver
    2016
    Posts
    974

    Re: Macron running extremely slow after update to Excel 2016

    I do not know if this will totally fix your problem (seems unlikely), but it should reduce running time.
    This is not tested. Suggest you try this in a copy of your file first!


    Please Login or Register  to view this content.
    replaced with this notation
    Please Login or Register  to view this content.
    and replaced Cells(x,y) with .Cells(x,y)
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    11-20-2012
    Location
    stockholm
    MS-Off Ver
    Excel 2010
    Posts
    123

    Re: Macron running extremely slow after update to Excel 2016

    Quote Originally Posted by Kevin# View Post
    I do not know if this will totally fix your problem (seems unlikely), but it should reduce running time.
    This is not tested. Suggest you try this in a copy of your file first!


    Please Login or Register  to view this content.
    replaced with this notation
    Please Login or Register  to view this content.
    and replaced Cells(x,y) with .Cells(x,y)
    Please Login or Register  to view this content.
    Hi Kevin,

    Thanks for showing an interest in my problem. The new code fails, with the error message "Object doesn't support this property or method". It stops at

    Please Login or Register  to view this content.
    Any ideas?

    Thanks,
    Martin

  6. #6
    Valued Forum Contributor
    Join Date
    01-03-2016
    Location
    Conwy, Wales
    MS-Off Ver
    2016
    Posts
    974

    Re: Macron running extremely slow after update to Excel 2016

    oops - my error. Put the "." in the wrong place
    try this

    Please Login or Register  to view this content.

  7. #7
    Forum Contributor kalbasiatka's Avatar
    Join Date
    02-27-2016
    Location
    Brest, Belarus
    MS-Off Ver
    2021
    Posts
    224

    Re: Macron running extremely slow after update to Excel 2016


    Please Login or Register  to view this content.

  8. #8
    Forum Contributor
    Join Date
    11-20-2012
    Location
    stockholm
    MS-Off Ver
    Excel 2010
    Posts
    123

    Re: Macron running extremely slow after update to Excel 2016

    Quote Originally Posted by Kevin# View Post
    oops - my error. Put the "." in the wrong place
    try this

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

    Works now. The macro is running at least 10 times as faster now :-)

  9. #9
    Valued Forum Contributor
    Join Date
    01-03-2016
    Location
    Conwy, Wales
    MS-Off Ver
    2016
    Posts
    974

    Re: Macron running extremely slow after update to Excel 2016

    Great.

    You usually do not need to select ranges in VBA. Just tell vba what to do with things. It can usually do that without having to "pick them up"

    The "Select" command is very slow.
    Your code contained "Select" inside big loops, so the code was "Selecting" every time it passed through the loop.
    I would have expected this issue to have been there before you upgraded to Excel2016 too.

    Please mark the thread as solved

+ 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. Replies: 1
    Last Post: 09-09-2013, 03:41 AM
  2. [SOLVED] Calculations running extremely slow, any suggestions
    By Dena in forum Excel General
    Replies: 1
    Last Post: 08-09-2013, 02:01 PM
  3. Sheet update extremely slow
    By bibleguy125 in forum Excel General
    Replies: 1
    Last Post: 02-17-2012, 11:30 AM
  4. [SOLVED] Copy/Drag Down for Data range's running extremely slow.
    By Hyflex in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-23-2011, 01:35 AM
  5. HELP! Extremely slow excel file
    By floripabay in forum Excel General
    Replies: 1
    Last Post: 06-29-2011, 06:07 AM
  6. program running extremely slow
    By Toidz77 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-24-2009, 01:03 PM
  7. Excel is extremely slow now
    By Martindelica in forum Excel General
    Replies: 0
    Last Post: 05-01-2007, 08:32 PM
  8. Excel vba script extremely slow
    By persenena in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-05-2005, 08:05 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