Can not make a control transparent. Help!

D

Daimy

Can not make a control transparent in XP.

Please help me.

Thanks!



public class Class1 : System.Windows.Forms.CheckBox
{

public Class1()
{
this.Left=50;
this.Top=50;
this.Width=32;
this.Height=32;

this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.BackColor=Color.Transparent;
}

}//



//FORM
public Form1()
{
Class1 obj=new Class1();
this.Controls.Add(obj);
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top