开发者

Picturebox transparency

开发者 https://www.devze.com 2023-01-14 19:14 出处:网络
can anyone help me how to apply transparency on picturebox on Winforms? I have a panel as a main container having a background picture, and I have a picturebox which overlapped on it. So all I need is

can anyone help me how to apply transparency on picturebox on Winforms? I have a panel as a main container having a background picture, and I have a picturebox which overlapped on it. So all I need is to have a transparency on pictu开发者_JS百科rebox.


Set the Backcolor property of the PictureBox to Transparent.

Ofcourse, make sure that the image you're using is transparent as well (i.e. no background color).


Go to the properties of the PictureBox and set the Back Color to "Transparent".

With code you can do it like:

    pictureBox1.BackColor = Color.Transparent;
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号