Of couse I help you to do your homework but as i said "I Help You
" not doing your homework.
If you mean in WinForm:
1. Create 2 Methods in code behind
private void DrawRectangle()
private void DrawEllipse()
Don't you know what method is? Methods (C# Programming Guide)
event of Buttons:
private void button1_Click(object sender, System.EventArgs e)
private void button2_Click(object sender, System.EventArgs e)
Don't you know about Click event? Control.Click Event
3. And what code should you substitue for //some code1 and //some code2 ?
Look at here: Drawing with Graphics in WinForms using C#
Sorry about forgetting something. (Thanks to SA) You also need a
to keep the drawn shapes. For example a
Of course after reading the last link you could find it out.