Well the name can be a little confusing. I have a database with a table. Companies that have a one-to-many switch with a different Sections table (so each company can have many departments), and the department will have many employees.
I have a listview of companies. I do not want that when I select a company from ListView, it includes another ListView of divisions within this company. Then I select a unit and another list of employees within these units, which are lower than this. You get an image.
Is there a way to do this mostly inside the XAML code declaratively (sp?). I use linq, so Company objects have a property called Division, which, if I understand correctly, that linq should include Division objects of the divisions associated with the company. Therefore, having received all the companies and setting them as the data source for CompanyListView, I am now.
<ListView x:Name="CompanyListView"
DisplayMemberPath="CompanyName"
Grid.Row="0" Grid.Column="0" />
<ListView DataContext="{Binding ElementName=CompanyListView, Path=SelectedItem}"
DisplayMemberPath="Division.DivisionName"
Grid.Row="1" Grid.Column="0" />
I know I'm leaving, but I was hoping that by putting something specific in the DataContext and DisplayMemberPath, I could get this to work. If not, then I have to capture the identifier of the company I am assuming and capture the selected event or something else.
, seconde, lisview, / . , , , , , , , - ?