// Gets called whenever drop down is changed public void OnJobChanged(object sender, Job job) { var jobChangeDelegate = JobChanged as EventHandler<JobChangedEventArgs>; if (jobChangeDelegate != null) { // raise event jobChangeDelegate(sender, new JobChangedEventArgs { Job = job }); } }
private void BindData(Job job) { this.DataContext = job; var emps = _Employees.Where(e => e.Jobs.Any(j => j.ID == job.ID)); EmployeesListView.ItemsSource = emps; }