wcf-ria-services

No key defined error on entity after branching in TFS

余生长醉 提交于 2020-01-06 07:38:24
问题 We are consistently getting the following RIA error message, after branching a team project in TFS: The Entity 'abc' in DomainService 'MyDomainService' does not have a key defined. Entity types exposed by DomainService operations must have at least one public property marked with the KeyAttribute. Everything works in the source branch, and when comparing the two branches there is absolutely no difference. I have also tried to install TFS 2012 on a virtual machine, import the project there,

Need help debugging: Having trouble getting data to Silverlight App through RIA Services, Entity Framework, MySQL

左心房为你撑大大i 提交于 2020-01-06 07:12:25
问题 I'm trying to build a Silverlight App that accesses and presents data from a MySQL database. I'm trying to use Entity Framework to model the MySQL data and RIA Services to make the data via EF available to Silverlight. My Silverlight App is showing the correct columns in the datagrid, but it does not show the data (alternate link to image) : When I look at the DomainService file (used for RIA Services), I see this: public IQueryable<saw_order> GetSaw_order(int intOrder) { return this.Context

RIA Services Server Side Exception Handling

ⅰ亾dé卋堺 提交于 2020-01-03 16:52:48
问题 I am trying to find out a way to handle unhandled exceptions at server side. I want control over exception handling at Domain Service level so that when any operation is called then I can log the exception and wrap it in some beautiful words to send it to the client. I found many ways for WCF and classic web services but nothing for RIA services. Please provide your suggestions. 回答1: You need to override the DomainService.OnError method as described in this WCF RIA Services Exception Handling

RIA Services Domain Service Class web.config setting

烈酒焚心 提交于 2020-01-02 07:18:11
问题 I've added a domain service class to the server side project of my SL4 / EF / RIA Services application. I've managed to create all the necessary elements needed in my web.config section. (Btw, why isn't this generated for me when I created my Domain Service Class?) What I'm missing now is what to put in the contract attribute of my endpoint element: <service behaviorConfiguration="XXX.Web.RIAServices.MyServiceBehavior" name="XXX.Web.RIAServices.MyService"> <endpoint address="http://localhost

How to combine .NET RIA Services with MVVM in Silverlight 3?

落爺英雄遲暮 提交于 2020-01-01 18:09:11
问题 The .NET RIA Services are described as an n-tier framework for Silverlight. I have been wondering what the relation is between this framework and the Model-View-ViewModel pattern. Are they in conflict or can you see the potential for synergic combination? 回答1: .NET RIA Services and MVVM are synergistic, and aren't in conflict. For example, if I write a Catalog domain service that exposes Products and Categories on the server, and correspondingly have a Catalog domain context on the client...

Entity Framework ObjectContext in windows/WPF/Silverlight application

╄→尐↘猪︶ㄣ 提交于 2020-01-01 05:43:07
问题 We are writing a WPF application using Entity framework (Silverlight with RIA services to be precise). We're using a shared ObjectContext through the application so that we can benefit from sharing data across the modules. The problem is - if user during his work opens let's say historical sales, it gets loaded to the ObjectContext and stays there until the end of the application. So another pattern should be used. I know that ObjectContexts should be used as single Unit-of-Work. But then,

Combining .NET RIA Services and MVVM in Silverlight 3.0

十年热恋 提交于 2019-12-31 23:42:23
问题 When using .NET RIA Services and MVVM in Silverlight 3.0 is there a difference between the Metadata type from RIA Services and the ViewModel from the MVVM pattern? Are these the same thing or should they be keep separate? The metadata type is a sealed internal class to the partial Entity class. There doesn't seem to be a proper separation there but the metadata type can also be decorated with attributes for Validation which makes it look like a ViewModel. I've searched around but I didn't see

Silverlight: Use of a local WCF service for business logic (intermediate WCF Service)? (Ria services in conjunction with a normal WCF Service?)

我的梦境 提交于 2019-12-25 04:48:11
问题 I have my silverlight calling my WCF service and its working great. This is a WCF (not ria) service that basically returns enitites or collection of entities. I really don't have control over it to add additional items just for silverlight for example. So i was thinking but maybe its bad performance or desgin.. But to have a local WCF Service hosted with the Asp.net website that hosts silverlight.. ANd i can use this wcf service for business logic that doesn't need to return entities. For

exposing Associated entities in ria services

只谈情不闲聊 提交于 2019-12-25 04:29:31
问题 I have read this link :- RIA Services: Entity Framework Reference Entities and added [Include] in metadata class as well as in my domain service query. On my client side i have a navigation property named Photos in my Albums entity. However it is of type EntityCollection and i don't know how to iterate over it. It has no get method and even indexing doesn't apply on it. I have tried the following :- albums.photos[0] but it doesn't work. Can anybody tell me how do i iterate over that photos

RIA Services Library not creating expected folder

徘徊边缘 提交于 2019-12-25 02:25:01
问题 When adding a new project and choosing WCF RIA Services Class Library, my solution shows one additional project, say, RIAServicesLibary1. However, there is no RIAServicesLibrary1.Web project shown. However, if I browse to the solution in windows explorer, I see both RIAServicesLibrary1 and RIAServicesLibrary1.Web folders. The RIAServicesLibrary1 folder is populated with files, but the .Web folder is completely empty. I have been trying to figure out why this is happening to no avail. I have