Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

ItemsControl and Expander !

$
0
0

Hi Everyone,

I want to load a bunch of UserControls (views) through ItemsControl (?) but I want each one of them to get encapsulated in expanders.

It should look like this:

So I was having something like:

              <ItemsControl ItemsSource="{Binding Path=ViewCollection}">
                <ItemsControl.ItemTemplate>
                    <DataTemplate>
                        <Expander/>
                    </DataTemplate>
                </ItemsControl.ItemTemplate>
                </ItemsControl>

Of course it is not working!

What I can do to achieve this?

Thank you.


Please Mark as Answered If this answers your question OrUnMark as Answered if it did not.
Happy to Help :)
My Site


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>