private void Historal_Click(object sender, RoutedEventArgs e) { HistorialView addFactura = new HistorialView(); ModifyClienteViewModel viewModel = this.ConvertDataContext(this.DataContext); addFactura.DataContext = viewModel.CreateHistorialViewModel(); addFactura.ShowDialog(); }
private ModifyClienteViewModel ConvertDataContext(object dataSource) { ModifyClienteViewModel viewModel = dataSource as ModifyClienteViewModel; return(viewModel); }