Click here to Skip to main content
15,921,793 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

we got a WPF application based on the MVVM pattern. We show the logging data comming from a piece of hardware in a scrolling window.
The logging data (just strings) are written by the hardware continously into an ObservableCollection in the ViewModel.
This works fine. The capacity of the ObservableCollection is limited, e.g. to 1000 lines.
As soon as the limit is reached we want to remove older lines and fill in new logging data. (We would need a ring-buffer)
We tried to remove the first 30% of the collection an move the rest down to the beginning. But this didn't work with such a Collection.
We also tried to use a Queue<string>, which makes sense. But the WPF window did not update: Binding dosen't work.
Got any idea? Thanks

Updated 8-Aug-12 3:47am
flyingfysh 20-Jul-16 11:32am    
I am running into the exact same question. Unfortunately, the solution pointed to by Kenneth at is no longer there. The web site appears to be gone.

1 solution

The problem has already been solved:[^]
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900