MVVM Light Silverlight Question
Hi I've been getting started with MVVM in Silverlight. When you call your model from your viewmodel the model's call to it开发者_开发知识库's Web Service is asynchronous. What is the best way of notifying the view model when you have your data. Currently I just use the messenger class to fire it back a notification with the data set up a listener on the viewmodel. This works fine but I'm not sure it's the best way of doing it. Can anyone point me in the direction of some best practices? Cheers.
I recommend using the Reactive Extensions for that. Specifically, take a look at the Subject class.
精彩评论