Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 257
Default Turning off display while VBA running

Seems to me I once saw an option I can turn off to keep Excel from updating
the display while my program inserts rows, fills in data, hides/unhides rows
and such, so it'll run faster if there's a lot to be accomplished...the idea
being that the program will turn the display, so to speak, back on just
before it gets to End Sub. Now I want to use that feature and I can't find
it in my VBA/Excel chm. Can anyone tell me where to look for it? Thanks.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 298
Default Turning off display while VBA running

Application.Screenupdating

Tim

"Bob Bridges" wrote in message
...
Seems to me I once saw an option I can turn off to keep Excel from
updating
the display while my program inserts rows, fills in data, hides/unhides
rows
and such, so it'll run faster if there's a lot to be accomplished...the
idea
being that the program will turn the display, so to speak, back on just
before it gets to End Sub. Now I want to use that feature and I can't
find
it in my VBA/Excel chm. Can anyone tell me where to look for it? Thanks.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 698
Default Turning off display while VBA running

Try:

Application.ScreenUpdating = False
Application.ScreenUpdating = True

At the beginning and at the end of your code.

If your code calls other code to do some "stuff" then you may still get
screen flickering as that code excetutes, so you may need to include

Application.ScreenUpdating = False
Application.ScreenUpdating = True

in that called code also.

Also knowing that once you go to the other called code the
Application.ScreenUpdating = False is now negated in the original code and
when the code comes back to the next line of the original code and you may
get screen flickering again as it continues.

HTH
Regards,
Howard


"Bob Bridges" wrote in message
...
Seems to me I once saw an option I can turn off to keep Excel from
updating
the display while my program inserts rows, fills in data, hides/unhides
rows
and such, so it'll run faster if there's a lot to be accomplished...the
idea
being that the program will turn the display, so to speak, back on just
before it gets to End Sub. Now I want to use that feature and I can't
find
it in my VBA/Excel chm. Can anyone tell me where to look for it? Thanks.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,942
Default Turning off display while VBA running

hi
at the begining of our code, add this......
Application.ScreenUpdating = False

then before the sub finishes, add this.......
Application.ScreenUpdating = True

if you turn screenupdating off, always be sure to turn it back on.

Regards
FSt1
"Bob Bridges" wrote:

Seems to me I once saw an option I can turn off to keep Excel from updating
the display while my program inserts rows, fills in data, hides/unhides rows
and such, so it'll run faster if there's a lot to be accomplished...the idea
being that the program will turn the display, so to speak, back on just
before it gets to End Sub. Now I want to use that feature and I can't find
it in my VBA/Excel chm. Can anyone tell me where to look for it? Thanks.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
display message while code is running Bassman62 Excel Programming 5 November 10th 08 08:15 PM
How to display running-down numbers with total count? Tetsuya Oguma Excel Worksheet Functions 1 October 10th 07 04:07 AM
display an info ballon or message box while a macro is running Micah Excel Programming 0 November 15th 05 01:21 PM
How to display a form- to show status of the running program Joseph Excel Discussion (Misc queries) 2 May 31st 05 11:31 AM
How to display status and keep code running ExcelMan Excel Programming 1 September 20th 03 04:31 AM


All times are GMT +1. The time now is 02:53 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"