Reader Level:
Articles

Drawing With no OnPaint Method

By Mahesh Chand on August 09, 2001
In this sample example, I draw GDI+ objects on button click.
  • 1
  • 0
  • 19972
Download Files:
 

Couple of people have asked on discussion forums about drawing with no OnPaint method or event. 

Why OnPaint method? The main reason is we can get Graphics object easily on paint method. Actually painting with no OnPaint method is very simple. Just you need Graphics object for the form you're drawing on.

In this sample example, I draw GDI+ objects on button click.

Mahesh Chand

Mahesh Chand is founder of C# Corner. C# Corner founded in 1999 is a FREE member contributions based open platform for developers to solve problems, learn new technology and hang out.  Mahesh has been awar... Read more

COMMENT USING

Trending up