![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
| |
| | #1 (permalink) |
| | DataBinding and ListView I have an application with two ListViews. The datasource of the ListView is created with a converter (see XAML code). I use a converter for the ListView for the following reason: when the selected entity is an inactive entity: by default it isn't loaded into the List. The converter add the inactive entity to the list with the active entities. When I select a specific project in the first ListView, the data in the second ListView must be reloaded and based on the selected activity in the first ListView. How can I achieve this in XAML? (The ListViews are nested in a DataTemplate) <ListView Name="LstProjects" MaxHeight="200" VerticalAlignment="Stretch" ItemsSource="{Binding Mode=OneTime, ConverterParameter=Event.Project, Path=Project, Converter={StaticResource projectDataSourceSelector}}" SelectedItem="{Binding Project}"> </ListView> <Label FontWeight="Bold">Project activity</Label> <ListView Name="LstProjectActivities" VerticalAlignment="Stretch" ItemsSource="{Binding Mode=OneTime, ConverterParameter=Event.ProjectActivity, Converter={StaticResource projectActivityDataSourceSelector}}" SelectedItem="{Binding ProjectActivity}" MaxHeight="200"> </ListView> |
My System Specs![]() |