Synchronizing collection changes from server to client in WCF RIA Silverlight
We have a silverlight client using RIA Services. We have UI controls (such as a listbox) which we bind to collections on the server.
We want the listbox to automatically update itself when the collection on the server changes. So far we can get this behavior if we bind to a local collection (in the silverlight client, and we have dependency propeties, etc开发者_开发百科) and update that list ... then the control updates automatically. But we cannot get a listbox to update when the server collection changes.
Is there some trick or setting to getting RIA to convey changes in collections from server to client? Or if not, is there a good way to accomplish this?
Thank you !
Current WCF RIA Services doesn't provide data change notification from server.
Check this WCF RIA Services Forum here
IMO, server polling with timer in sl client or using WCF duplex channel might be solution.
My case, I use direct TCP/IP socket in Silverlight client with server-side. But socket is not supported Winphone7 version currently.
These are some solution discussion links for server notification in WCF RIA.
-http://forums.silverlight.net/forums/p/141880/459974.aspx
-http://forums.silverlight.net/forums/p/183265/415583.aspx#415583
Might this helps!
精彩评论