<Grid> <ListBox x:Name="Lst"> <ListBox.ItemTemplate> <DataTemplate> <Button MouseDoubleClick="Button_MouseDoubleClick"> <Grid> <Image Source="{Binding Path=BackGround}" /> <TextBlock Text="{Binding Path=Name}" Margin="70 10" FontSize="18"></TextBlock> </Grid> </Button> </DataTemplate> </ListBox.ItemTemplate> </Grid>
WPF学习笔记——ListBox用ItemsSource绑定数据源
原文:http://www.cnblogs.com/lingda/p/5940357.html