-
In my View, there is a DataGrid bind to a collection in ViewModel. This collection is tranformed from a source cache in a service. So is there any way to speed up updating? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
10 seconds for 300 items is absurd, no matter what thread you're working on, you've got something more serious going on than just a "how do I make this faster" issue. Can we see some code? If that's not possible or feasible, we can start with some relevant questions... Where are these items coming from? Are you adding them one-at-a-time, or in a single batch? Or maybe a handful of batches? How is this collection exposed to the View layer? An Are you doing any kind of locking or thread-signaling to access the
That's basically the ideal practice. A) Make sure that users are given visual feedback when data is loading, and B) make sure that the user cannot interact with any UI elements that depend on that data, until it's loaded. |
Beta Was this translation helpful? Give feedback.
Sorry for the late response due to other works, I think I've figured out recently.
It is not revelant to Dynamic Data, but the COM STA limit for Office. Due to the STA, it has to read data from visio one by one, so it costs much more time than expected even all operation is invoked in the VSTO_Main thread. And it can't be worked around by parallel in background thread, because it will marshal all data to the COM automatically.
Thanks for your help.