Search code examples
wpfpanelcollapsiblepanelextender

How to create a collapsible panel in WPF


I am creating a Windows application (WPF) and C#. In my view, I have to add few layouts like browsing a folder, displaying the files in the folder in a list view...etc

My requirement is : The panels mentioned above should be collapsible panels, I guess, we dont have option of collapsible panel in wpf.

I have to create a custom control for this? If so, Please suggest me how to do this?


Solution

  • The Expander control may be what you are looking for. From MSDN:

    Expander Class

    Represents the control that displays a header that has a collapsible window that displays content.