Forum Discussion
David Griggs
Aug 15, 2018Copper Contributor
Application.ScreenUpdating
I have seen the other posts on this topic, where the property does not function in Excel 2016, but there still does not appear to be a remedy for this problem. I, like probably thousands of vba w...
Elle100
Jun 23, 2019Copper Contributor
Try this fix
Set the ScreenUpdating property on the Workbook object like this:
Workbooks("your workbook name.xls").Application.ScreenUpdating = False
' add your code in here
Workbooks("your workbook name.xls").Application.ScreenUpdating = True
where "your workbook name" is the workbook that you are updating.
I posted this fix on the excel suggestion forum too.
- Elle100Jun 23, 2019Copper ContributorSorry, I realized I had the workbook (to be updated) minimized and that's why it worked! Try this, although there might be better code to minimize a particular workbook window, the following was OK for me. Application.ScreenUpdating = False Dim wbName As Window Set wbName = Windows("your workbook name") wbName.Visible = False ' other code here Application.ScreenUpdating = True wbName.Visible = True
- Elle100Jun 23, 2019Copper Contributor
That didn't format very well, let me try again. Also, I found a neater way to minimize the workbook being updated.
Application.ScreenUpdating = False
Dim wbName As Window
Set wbName = Windows("name of workbook being updated")
wbName.WindowState = xlMinimized
' other code in here
Application.ScreenUpdating = True
wbName.WindowState = xlMaximized