Hidden panel borders affecting parent panel

5 posts, 0 answers
  1. Bob
    Bob avatar
    3 posts
    Member since:
    Aug 2015

    Posted 11 Nov 2015 Link to this post

    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.

  2. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 12 Nov 2015 Link to this post

    Hi Bob,

    Thank you for writing.

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

    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
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Bob
    Bob avatar
    3 posts
    Member since:
    Aug 2015

    Posted 12 Nov 2015 in reply to Stefan Link to this post

    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.

  5. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 13 Nov 2015 Link to this post

    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
  6. Bob
    Bob avatar
    3 posts
    Member since:
    Aug 2015

    Posted 13 Nov 2015 in reply to Stefan Link to this post

    Ah, got it.  That seems to do the trick.  Thanks!
Back to Top
UI for WinForms is Visual Studio 2017 Ready