Iorn Man
Iorn Man

Reputation: 267

Whats the difference between Invalidate and OnPaint

In my Winforms application, I want to send a Paint request.

Which method should I use? Also, what's the basic difference between Invalidate and OnPaint ?

Upvotes: 0

Views: 233

Answers (1)

benPearce
benPearce

Reputation: 38343

OnPaint is the method where the actual painting takes place.

Invalidate is a way of requesting that the control or form be repainted.

Whats the difference between Control.Invalidate, Control.Update and Control.Refresh?

Upvotes: 2

Related Questions