void FillTreeView() { client.CustNoCompleted += new System.EventHandler<CustNoCompletedEventArgs>(client_CustNoCompleted); client.CustNoAsync(); } void client_CustNoCompleted(object sender, CustNoCompletedEventArgs e) { TreeViewItem tvitem = new TreeViewItem(); tvitem.Header = "Customer"; List<Cust> cust = e.Result; var list = from o in cust select o.Customer_No; custtreeview.ItemsSource = list; //treeview.ItemsSource = list; }
<StackPanel Orientation="Horizontal"> <TextBlock Text="{Binding Name}" Margin="5,0" /> </StackPanel> </control:HierarchicalDataTemplate> </control:TreeView.ItemTemplate>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)