Sunil
Sunil

Reputation: 175

MDI Child form painting issue

  Do anyone have any comments about this issue.

enter image description here

This is a MDI Child form displayed inside a MDI Client.And when i overlaps the forms partially on to another form then its no fully repainted. Is this a painting issue.Do anyone have any idea.

Thanks in advance Sunil

Upvotes: 1

Views: 637

Answers (1)

Ali Vojdanian
Ali Vojdanian

Reputation: 2111

Try this :

 Form2 f2;    

private void button1_Click(object sender, EventArgs e)
{
    if (f2 == null) {
       f2 = new Form2();
       f2.MdiParent = this;
       f2.FormClosed += delegate { f2 = null; };
       f2.Show();
    }
    else {
       f2.Activate();
    }
}

Upvotes: 1

Related Questions