Maybe I am missing something, but is it the case that when you set a pictureboxes background to transparent, all it really does is set it to the same color as the forms background?

What I am trying to do is draw an animation for the benefit of this, a bouncing ball - which I paint on the form, then overlay that with a picture frame. End result should be a bouncing ball in a picture frame.

I have tried:

1.-Setting the picture box background to pink and then key out the same pink, this basically cuts away everything, including that which is behind the picture box
2. -Setting the picture box to transparent, this just displays the picture box background as the same color as the forms background.
3. I have tried painting the image in a rectangle, this had the same effect as drawing it in a picture box.

I am not sure what I am doing wrong, I am wondering if there is any other ways I could try or if someone has made a custom control or library that supports transparency?

EDIT: I should also mention the picture frame is not even, so I cannot use 4 seperate images arranged as a frame.

Have you tried using the image as the forms background, instead of using pictureboxes?
Unless, of course, you're using the background to draw the ball.
That would be the reason for why the ball is behind the picturebox instead of on top of it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.