May 20, 2005

Difference between Invalidate, Update and Refresh

Whats the difference between Control.Invalidate, Control.Update and Control.Refresh? See here for a detailed explanantion

Summary:
Control.Invalidate() => Mark region/rectangle for painting in when next WM_PAINT is received. Asynchonouse
Control.Update() => Immediately send WM_PAINT to the WNDPROC() if update region is not empty. Synchonous
Control.Refresh() => Control.Invalidate() followed by Control.Update(). Synchonous

No comments: