Forum Discussion
Macros suddenly run much slower
My setup:
- Windows 11 Pro 64 bits Versie: 22621.1105
- PC with Intel(R) Core(TM) i7-10700 CPU @ 2.90GH and 16 Gb of Memory
- Video NVIDIA GeForce GTX 1650
- Microsoft 365 Family with latest update
I struggle with the following problem in Excel 365 (and even more problems i will post in a different message).
I made an excel-application I want to bring to the market soon. In Excel 2016 it runs like a charm, but in Microsoft 365 Excel macro's run sooooow slooowwww in Microsft 365. At the office we use Office 2016 and it runs all smooth. Does microsoft even look into this problem that exist since 2022? I don't see any progress!!
The most noticable slow downs for me when doing the following action through VBA:
- Insert, delete or move a line or column on a sheet
- Hide and unhide lines or columns on a sheet
An example from my application:
- I have a userform and underlying macro to create a pdf from a sheet
- It is a very big sheet with a lot of formulas and data
- With the userform I can select wich part, wich lines or wich Columns from the sheet wil be hidden before saving it to pdf
- Then when it hides the lines/columns it is slow, but when it unides the lines after saving the pdf it is even much slower
- In office 2016 it takes max 10 seconds to unhide the lines, save to pdf, show the lines again and close the macro; In Microsft 365 it takes more then 1 minute!
- And Yes..... I use 'application.screenupdating = false' and 'application.calculation = xlcalculationmanual' at the start of the subroutine. So the screen stays stady until the macro stopt running.
The suggestions in this Thread doent work for me!
When the problem stays like this i will go back to office 2019 of 2021, or do I even have to go to office 2016? Does Anyone know if the architecture of Microsoft 365 is differtent from the Office versions 2016,2019,2021?
PLEASE MICROSOFT SOLVE THIS!
For such issues I would typically collect the information lines on one sheet or area, then have another sheet or range where I copy cells as needed, using e.g. 'unique' or a separate numbered column to sort the information and remove empty lines, rather than actually hide lines.