Command button working invisibly

imback2nite

Board Regular
Joined
Oct 30, 2004
Messages
110
Office Version
  1. 2007
First time poster, long time reader here.
I am working on a spreadsheet with two command buttons. One button that will hide certain columns while other colums become visible. The second Command button will to the same...just vice versa. When I hit the button I see all the colums emerging and then disappearing. My question is.....Can I have the buttons work without seeing all the goings on? I mean can I hit the button and wait the second or two and NOT see what columns are disappearing and reappearing? Thanks for the help in advance!!!
 

Some videos you may like

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

Fritz24

Board Regular
Joined
Sep 8, 2004
Messages
102
Before the bulk of your code enter the line:

Application.ScreenUpdating = False

and before the end of the code

Application.ScreenUpdating = True
 

imback2nite

Board Regular
Joined
Oct 30, 2004
Messages
110
Office Version
  1. 2007
Fantastic!!

Works like a charm!!! Thanks!!! Now tha page doesn't bounce around making me dizzy!!!
 

Watch MrExcel Video

Forum statistics

Threads
1,118,674
Messages
5,573,597
Members
412,537
Latest member
Mohamed_5966
Top