views:

983

answers:

3

So the transparent background problem is solved. Now, every time I show the form (or have to have it repainted), I get a lot of flickering. Is there any way I can not update the screen until the paint event is complete, or any other way to stop the 1/2 second of flickering and flashing while all the objects are being painted?

ANSWER: Double buffering is the way to go. I was already double buffering on the control, but it has to be set on the form. I though double buffering only worked when you were subclassing OnPaint yourself.

+7  A: 

Did you try setting the DoubleBuffered property for the form?

Gulzar
+1  A: 

Set the DoubleBuffered Property on the form.

Kyle Trauberman
+5  A: 

Double Buffering might help, another thing you might want to try is:

SuspendLayout();

dostuffhere...

ResumeLayout();

schmoopy
DoubleBuffered _increases_ resource requirements, but is more likely to be effective. Suspend/ResumeLayout() _reduce_ resource requirements, but are less likely to be effective.
Joel Coehoorn