+ Reply to Thread
Results 1 to 3 of 3

slow macro help Excel 2016/2019

  1. #1
    Registered User
    Join Date
    09-26-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    slow macro help Excel 2016/2019

    Hello, I am having trouble with a recorded macro that used to work fine under previous versions of Excel, but runs extremely slow on Excel 2016/2019. It will initially work pretty quickly on a new computer, but as the macro is repeated, it will extremely slow down, and it will remain that way regardless if the computer is rebooted or not. Works with no issues under Excel 2010 or previous Excel.

    Objective: I have a set of data that needs to be copied over from one spreadsheet with masterdata (call it "SpreadsheetB" below) to another spreadsheet (call it "SpreadsheetA" below) at a certain cell, and then once that set of data in "SpreadsheetB" is done, it moves over to the next column in "SpreadsheetA" so I can repeat the macro again.

    1. I have zero clue on VB coding (I can sort of make out what it is doing when it is written out)
    2. The macro was created/re-created multiple times using conditional references and record macro
    3. Offset needs to remain as is as that's how the location(s) of the provided data and that's where the destination pasting should go to
    4. I have searched the internet to add in whatever codes that supposedly make it go faster (screen updating, display status bar, etc.)
    5. I understand that the way it is doing it right now with Selections and Activate is not the most efficient way to do it so that's why it's slowing down on new version of Excel, but I don't know how to code it.

    The macro that I am having problem is coded as below:

    Please Login or Register  to view this content.
    Last edited by kebosabi; 05-06-2020 at 06:46 PM.

  2. #2
    Registered User
    Join Date
    09-26-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: slow macro help Excel 2016/2019

    I've also attached sample SpreadsheetA and SpreadsheetB as an example.

    The recorded macro is inside SpreadsheetA with the macro name THREEWKUPD, and will work with the shortcut Ctrl+w

    1. Open both files
    2. SpreadsheetB start point cell E2
    3. SpreadsheetA start point cell E516
    4. run macro Ctrl+w (copies yellow highlights)
    5. at the end of the macro run, macro will move SpreadsheetB start point to E24, SpreadsheetA start point to F516
    6. run macro (copies light green highlights)
    7. keep running macro until SpreadsheetB start point reaches E90 (BrA Apple Yellow Beta), manually move start point on SpreadsheetA start point to J516
    8. So on and so forth, manually move start point on SpreadsheetA as needed (another worksheet tab, etc.)

    Basically, it's copying a set of data from SpreadsheetB to SpreadsheetA at the specific transpose-paste locations to another.
    Attached Files Attached Files

  3. #3
    Valued Forum Contributor
    Join Date
    08-07-2014
    Location
    Quito, Ecuador
    MS-Off Ver
    Excel 2016 & 365, Windows 10
    Posts
    511

    Re: slow macro help Excel 2016/2019

    Hi kebosabi

    You MUST avoid the use of "Activate" and "Select" , unless it is absolutely necesary.
    Here I attach the first part of your code modified .

    You have 45 procedures of copy/paste,
    most of them use an offset of 5 down.... but in a few instances (#9, 16, 31 and 38 ) the offset is 12 down
    where I got lost was in the 23th instance... thero you play all around the sheet...
    All of this could be easily solved y only one loop to repeat all the instances.
    Check, and try to finish the conversion.

    Please Login or Register  to view this content.
    Barriers are there for those who don't want to dream

+ 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. VBA to create and send emails with attachments 2019 ok/2016 not ok!
    By he2368 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-27-2020, 10:09 AM
  2. Excel 2016: xlsm files slow to save
    By jkotsonas in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-26-2019, 11:16 AM
  3. Replies: 1
    Last Post: 03-18-2019, 09:02 AM
  4. Migrating Excel 2016 to Excel 2019
    By ImranBhatti in forum Excel General
    Replies: 8
    Last Post: 10-26-2018, 11:35 AM
  5. Excel 2016 Extremely Slow
    By fornight in forum Excel General
    Replies: 4
    Last Post: 10-20-2017, 10:12 AM
  6. Replies: 1
    Last Post: 10-11-2016, 02:13 PM
  7. [SOLVED] Macron running extremely slow after update to Excel 2016
    By masben in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 03-08-2016, 11:26 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