I have a List view with Custom item container style which has two textblocks each binded to an property in the model used in the ViewModel's observableCollection
When i click an item i want it to show a new window containing more model properies based on the clicked item.
here is some of the code
// The model
public class Activity
{
public string Title {get; set;}
public DateTime CreationDate {get; set;}
public string MoreDetails {get; set;}
}
// The ViewModel
public class ViewModel
{
public ObservableCollection<Activity> Activities {get; set;}
public ViewModel
{
//Here i have pre added Activity objects to Activities
}
}
the ListView 's ItemsSource binded to Activities the first text block is binded to title and the second is to Date (in the Item style) sorry if this is a bit confusing i am new to WPF . im not on visual studio rn to show xaml
i have a second window which is supposed to show up with MoreDetails property binded in a textblock when an item is clicked How can i do that?