Click here to Skip to main content
15,886,797 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I have following layers in my applicaiton
Date Layer (reference to Model)
Business Layer(reference to Model ,Data)
Model
Service(WCF)-(reference to Model,Business Layer)
UI (WPF/Silver Light) - Connected via WCF service

How do i detect the changed poco entities in an ObservableCollection in UI layer?
for sending it back to server from client side for saving ? instead of sending all data back to sever side(via WCF)?

or

how to perform add/delete/update operation on entities in the collection in UI layer?

I am using
VS2010/2012
C#
EF 5
ADO.NET POCOEntityGenerator With WCF Support(for generating .tt templates from Model.edmx)
SQL Server 2012

Even though searched a lot of places I didn't find a proper solution..
please help if any ideas...

Thanks...

I developed my application using the method given in following link..

http://www.toplinestrategies.com/dotneters/net/wcf-entity-framework-and-n-tier-solutions-part-2/?lang=en/comment-page-1/#comment-1954[^]

Any one know how to do save method (CRUD) of each row in gridcontrol in the pattern given in above link
Posted
Updated 4-Dec-13 18:16pm
v3

1 solution

I was going to be helpful right up until I saw that you are using EF. My short answer would be that you don't, you have to implement INotifyPropertyCahnged in your model.

We reference the model project from both the WCF and the UI projects.
 
Share this answer
 
Comments
Sadique KT 5-Dec-13 3:57am    
Please check the above link.. My UI is communicating using WCF and my service project has reference to Model.
Mycroft Holmes 5-Dec-13 4:18am    
I don't know EF, we use our own DAL and then populate the Model from a datatable in the WCF. The models are in their own project and implement INotifyPropertyChange.

The client project also references and reuses the same model project (we are doing Silverlight).
Sadique KT 5-Dec-13 4:34am    
I think you are not using POCO objects !!..
Mycroft Holmes 5-Dec-13 7:36am    
Of course I'm not using POCO objects, I told you my model implement INotifyPropertyChange, they can't be POCO. POCO object CAN'T tell anyone anything they are DUMB. I told you this in my very first response.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900