Hi All
Really need you help?
I have a List of simple class objects in my code behind, which I want to data bind to a Stack Panel.
Simple Class
public class MyBook {
public string Name = "Physics";
public decimal Price = 9.99;
}
Window Code-Behind - Property
public List<MyBook> BookData {
get;
set;
}
In my XAML I have the following StackPanel, which I want to data bind the propertyBookData too.
<StackPanel x:Name="spBooks" Margin="10 0 0 0" ><Label Content="Book Name"></Label></StackPanel>
For each item in the List<MyBook>, I want to insert a Label within the Stack Panel.
Any help would really be appreciated, Thanks!