ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Turn screen update off; then back on during macro (https://www.excelbanter.com/excel-programming/438273-turn-screen-update-off%3B-then-back-during-macro.html)

dan

Turn screen update off; then back on during macro
 
I'm new to Excel VBA and struggling with syntax.

I have a macro tied to a form command button. I'd like to:

1. Turn the Excel screen update(s) off;
2. Run the code on the button;
3. Turn the Excell screen updates back on.

Is there a method/class/whatever to do this? The macro adds data to a
couple of worksheets; I'd like the macro to run without showing the user
what's going on.

Thanks! in advance.

--Dan

John[_22_]

Turn screen update off; then back on during macro
 
Hi Dan
Put this at the beginning of your macro:
Application.ScreenUpdating = False
This one before End Sub
Application.ScreenUpdating = True
HTH
John
"Dan" wrote in message
...
I'm new to Excel VBA and struggling with syntax.

I have a macro tied to a form command button. I'd like to:

1. Turn the Excel screen update(s) off;
2. Run the code on the button;
3. Turn the Excell screen updates back on.

Is there a method/class/whatever to do this? The macro adds data to a
couple of worksheets; I'd like the macro to run without showing the user
what's going on.

Thanks! in advance.

--Dan



dan

Turn screen update off; then back on during macro
 
:) Thanks!

"John" wrote:

Hi Dan
Put this at the beginning of your macro:
Application.ScreenUpdating = False
This one before End Sub
Application.ScreenUpdating = True
HTH
John
"Dan" wrote in message
...
I'm new to Excel VBA and struggling with syntax.

I have a macro tied to a form command button. I'd like to:

1. Turn the Excel screen update(s) off;
2. Run the code on the button;
3. Turn the Excell screen updates back on.

Is there a method/class/whatever to do this? The macro adds data to a
couple of worksheets; I'd like the macro to run without showing the user
what's going on.

Thanks! in advance.

--Dan


.


John[_22_]

Turn screen update off; then back on during macro
 
You're welcome Dan
I'm new to VBA myself, but knew your answer.
Regards
John
"Dan" wrote in message
...
:) Thanks!

"John" wrote:

Hi Dan
Put this at the beginning of your macro:
Application.ScreenUpdating = False
This one before End Sub
Application.ScreenUpdating = True
HTH
John
"Dan" wrote in message
...
I'm new to Excel VBA and struggling with syntax.

I have a macro tied to a form command button. I'd like to:

1. Turn the Excel screen update(s) off;
2. Run the code on the button;
3. Turn the Excell screen updates back on.

Is there a method/class/whatever to do this? The macro adds data to a
couple of worksheets; I'd like the macro to run without showing the user
what's going on.

Thanks! in advance.

--Dan


.




All times are GMT +1. The time now is 05:53 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com