DEV Community

Andrews
Andrews

Posted on • Originally published at geekexcel.com on

What Application.Screenupdating = False Means, and Why is it Used in VBA?

In this tutorial, we will guide you to learn What Application.Screenupdating = False Means, And Why Is It Used In VBA. Let’s get them below!! Get an official version of MS Excel from the following link: https://www.microsoft.com/en-in/microsoft-365/excel

ScreenUpdating

Screenupdating is the property of application objects in VBA. It can be set to TRUE or FALSE. It is like a switch, that can be turned On or Off.

Example

  • Firstly, in the Excel Worksheet, you have to go to the Developer Tab.
  • Then, you need to ** ** select the Visual Basic option under the Code section.

Select Visual Basics

  • Now, you have to copy and paste the code given below.
 Sub Screencheck()
 Application.Screenupdating=FALSE 'Disabling the screen updating.
 Sheet1.Activate
 Range("A1").value ="Hi"
 Range("A2").value ="How are you?"
 Range("A3").value ="GeekExcel is amazing, isn't it?"
 Sheet2.Activate
 Application.Screenupdating= TRUE 'Enabling the screen updating.
End Sub

Enter fullscreen mode Exit fullscreen mode
  • After that, you need to save the code by selecting it and then close the window.

Save the Code

  • Again, you have to go to the Excel Spreadsheet , and click on the Developer Tab.
  • You need to choose the Macros option in the Code section.

Macros option

  • Then, you have to make sure that your macro name is selected and click the *Run * button.

Run the Code

  • Now, you will receive an object required dialog box , and then you have to click OK.

Object Dialog box

  • Finally, you will get output as given below in the Excel.

Final output

Verdict

In this tutorial, we guided you to know What Application.Screenupdating = False Means, And Why Is It Used In VBA. Leave your queries/suggestions in the below comment section. Thanks for visiting Geek Excel. Keep Learning!

Keep Reading:

Top comments (0)