0

Good afternoon!

I have several user controls, each one with a picture box containing an image. A user control represents the backgroud and the other two are elements that must be overlayed.

pictureBox_background.BackColor = Color.Black;
pictureBox_A.BackColor = Color.Transparent;

pictureBox_background.Controls.Add(pictureBox_A);
pictureBox_background.Controls.Add(pictureBox_B);
pictureBox_B.SendToBack();
pictureBox_A.BringToFront();

With this code I get the picturebox A is over picturebox B, but I can not make the background of the element A is the image of the picturebox B. The pictureBox A reaches the background picturebox, and it's background is the black color of the background picturebox. That is, the transparency of picturebox_A don't shows the picturebox_B, shows the black background, without showing the image of the medium (picturebox_B).

It's a little hard to explain. I hope it was understood. Thanks in advance!

jd142
  • 1
  • Does this question and its answers help you? [Make overlapping picturebox transparent in C#.net](http://stackoverflow.com/questions/4623165/make-overlapping-picturebox-transparent-in-c-net) – cbr Nov 16 '15 at 18:52
  • Nesting works fine, overlapping does not work well. – TaW Nov 16 '15 at 21:01

0 Answers0