I have several places in our application where I need to lay UltraLabels over a picture(UltraPictureBox). However, even though the background of the UltraLabel is transparent, it does not draw the picture underneath it in the area of the UltraLabel. It just draws the background color of the control underneath it but not the picture. Is there something I may be doing wrong, or is this a limitation of Infragistics or .NET?
Thanks,
Bill
Try this:
Create a CustomControl that inherits UltrLabel.
Add this code inside your CustonControl:
{
get
cp.ExStyle |= 0x20; // WS_EX_TRANSPARENT
}
The way that .NET transparency works is that a transparent control's region is painted by its parent, so in your case if the label is not a child control of the UltraPictureBox (which I don't think is possible), this will not work. You could try setting the BackgroundImage property of a .NET Panel instead and put the label inside of that panel.
-Matt