Why BackColor of MDI child cannot be Color.Transparent?

E

Efkas

I am trying to build a MDI windows form, with child including some
stuff, but it seems to be impossible to have BackColor property set
to Color.Transparent.

Is it existing any solution to have the background of a child window
of MDI transparent?

Thanks
François

*-----------------------*
Posted at:
www.GroupSrv.com
*-----------------------*
 
P

Philip Rieck

Set the back color of the form to something unused (like magenta).

Then set the form's transparencykey to that same color.
 
P

Peder Y

Hi!
There are several workarounds for this problem. Bob Powell's GDI FAQ
has some approaches on how to make a control transprent. I believe you
can adopt one of his solutions. Another workaround would be to pick a
transparencyKey color for your form, and make sure all other elements
have colors except this one. A third posibility is to define a path
that describes which parts that are visible and which that are not.
The choice of solution depends on how complicated and dynamic you want
your application to be.

Good luck!

- Peder -
 

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