Application.ScreenUpdating = False and it still flicker !

  • Thread starter Thread starter Gunnar Johansson
  • Start date Start date
G

Gunnar Johansson

Hi,

I try once again since I didn't get a usable respons last time.

I have "Application.ScreenUpdating = False" in first row after "Sub.." and
has
it as "= True" the last line just before "End Sub"

I belive many of you find this flickering but for some, often smaller
macros, there is NO flickering. The question is - WHYdoes it occure when
screenupdating=false? Is it just some special commands, is it the length of
the code, is it the screenupdating=false command itself??? ... or?

If some of you know if there is some special commands that create screen
flicker despite screenupdating=false, please tell so I can try to avoid it
and use other
solutions instead.

/Regards
 
Hi Gunner,

I think it is normal sometimes to expect a flicker when screenupdating
is set to true, even if it was previously "true". Depending on what's on
the screen when done this may not be noticeable, but try this:

Draw a large rectangle with a diagonal two colour fill effect. Then run
the single line:
Application.screenupdating = True

If you are running the same Sub many times in your overall code, you
could well see the screen flicker each time. So ensure screenupdating is
only reset once in an entire run of code. Say, False just before
anything that's going to change what's on the screen and True when there
will be no more changes. Might require moving the screenupdating code to
different Sub('s).

Regards,
Sandy
 
Post your code and others can see if they can reproduce it or recognize what
might be problematic.
 
Try these lines i use them and experience no flicker!

End With
Application.Cursor = xlWait
Application.EnableEvents = False
ActiveWorkbook.PrecisionAsDisplayed = False
Application.ScreenUpdating = False

***YOUR CODE***
Application.ScreenUpdating = True
ActiveWorkbook.PrecisionAsDisplayed = True
Application.EnableEvents = True
Application.Cursor = xlDefault

HTH

Simo
 
Sorry, I think my application is to large for the usergroup. The code
sometime call other subs etc. It is hard to separate the code.

Maybe I found one reason however - to ensure the formats in the sheets, I
run cells.copy at a "rerference sheet" and "cells.pastespecial " to paste
formats in to the activesheet. This might cause some small differentces in
column with and row height. Maybe I should paste values into the reference
sheet "up to date". Maybe that I see is a format paste to the activesheet
from the "reference sheet" and then a fast reformation to the cells with
values.

I report later the outcome of this,

Thank you all
 
Sorry simon,

I didn't notice any difference, but of cource could there be a reason to
write as you suggest in other circumstances. Look at my other posting about
my matter.

/Regard
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top