1
votes

I'm deleting a user from my GridView, but when I delete it. I first need to refresh my page to see the result.

Anybody any idea?

This is where I try to rebind the datasource

if (e.PropertyName == "deleted")
            {
                RadGridView1.ItemsSource = null;
                RadGridView1.DataContext = null;
                RadGridView1.DataContext = _viewModel;
                _viewModel.GetCovrUsers();


                RadGridView1.ItemsSource = _viewModel.CovrUsers;
                this._viewModel.PropertyChanged -= _viewModel_PropertyChanged;

            }
1
You can use ObservableCollection class and when you delete an item from a collection of this type, the UI will be updated respectivly. - vortexwolf

1 Answers

0
votes

You can use Inotify Property change.