Right now I have a WPF DataGrid that displays a list obtained from a LINQ to Entity query. That however does not mean that if I delete something from my data base, it’ll be removed immediately from the DataGrid. I tried myGrid.Items.Refresh(), but it refreshed only one cell.
I know the ObservableCollection could somehow solve the problem but I don’t know where to create such collection and proper methods so that whenever I create/add/modify database, the collections gets modified too.
The DataGrid has the data from the time the query was run.
If you want fresh data you need to rerun the query.
Query Notifications in SQL Server
If you are not using MSSQL let me know and I will delete the answer.