WPF给容器类控件绑定源,动态生成控件

 1 <ItemsControl x:Name="itemsControl">
 2 <ItemsControl.ItemsPanel>
 3 <ItemsPanelTemplate>
 4 <WrapPanel Orientation="Horizontal"/>
 5 </ItemsPanelTemplate>
 6 </ItemsControl.ItemsPanel>
16 </ItemsControl>
原文地址:https://www.cnblogs.com/usen521/p/12689840.html