This is a migrated thread and some comments may be shown as answers.

Hidden panel borders affecting parent panel

4 Answers 170 Views
Panel
This is a migrated thread and some comments may be shown as answers.
Bob
Top achievements
Rank 1
Bob asked on 12 Nov 2015, 12:06 AM

Hi - I need some help with rad panel borders in a WinForm.  I understand from other threads that the way to get a panel's borders to disappear is to set the PanelElement.PanelBorder.Visibility to "Collapsed".  This causes the border to disappear just fine, but it also affects the parent panel by making its borders disappear too.  See the attached image for how it looks.

Is there a way for me to get the child panels to have no border but also not affect the parent panel?  I want that border to remain as it is.

Side note: I have the two child panels inside the parent and set them to Dock left so that when the left control isn't needed that panel can be set to invisible and the panel containing the remaining controls will move to the left.

Thanks.

4 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 12 Nov 2015, 12:10 PM
Hi Bob,

Thank you for writing.

In addition to collapsing the border primitive, can you also try setting the inner panel BackColor to 

Let me know how this works for you.

Regards,
Stefan
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Bob
Top achievements
Rank 1
answered on 12 Nov 2015, 03:37 PM

I don't see Transparent as an option in the color dialog associated with the inner panel's BorderPrimitive BackColor property.  So I just typed the value in by hand and it doesn't seem to have any effect on the display.  I also tried it up a level on the RadPanelElement without effect.

0
Stefan
Telerik team
answered on 13 Nov 2015, 06:49 AM
Hello,

I mean the property of the control itself, not its elements. At design time, select the inner panel, and in the Properties window of Visual Studio, set the BackColor to Transparent.

Regards,
Stefan
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Bob
Top achievements
Rank 1
answered on 13 Nov 2015, 02:48 PM
Ah, got it.  That seems to do the trick.  Thanks!
Tags
Panel
Asked by
Bob
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Bob
Top achievements
Rank 1
Share this question
or