locked
CLR entity update not reflected in client? RRS feed

  • Question

  • Hi there, My RIA services are returning CLR objects and i have troubles getting the client code updated after changes to my entities on the server. For some reason, when i add simple datatypes my updates to the server side entities are updated / reflected on the client, but when i add a List of another serverside business object i never see the changes? Do you have any clue whats going on and how i can get it working? Below you see my businee object Provider which are supposed to contain a list of type Brands. The Brand list isnt available in my silverlight project. public class Provider { [Key] public int Id { get; private set; } public string Name { get; private set; } // This property is NOT updated / reflected on the client. public List BrandsListx { get; set; } //Adding the simple types below are reflected in my client public string X { get; set; } public string Y { get; set; } public string Z { get; set; } public Provider() { } public Provider(int id, string name, List brands) { this.Id = id; this.Name = name; BrandsListx = brands; } } Regards Niclas
    Thursday, March 18, 2010 3:00 PM

Answers

  • Your list of BrandsListx is treated by RIA Services as an association to the BrandsListx entity. To get them on the client you need to setup the AssociatonAttribute and IncludeAttribute.

    Thursday, March 18, 2010 7:53 PM