Entity Framework and layered structure

2 posts, 0 answers
  1. archimede
    archimede avatar
    103 posts
    Member since:
    Jul 2006

    Posted 26 Apr 2010 Link to this post

    I'm creating a new web application with Entity Framework. I want to use the following layered structure:

    User Interface Layer

    Business Object Layer


    Entity Framework Layer

    The Business Object Layer now implements the interface on bottom layer using the Entity Framework Objects.

    In the user interface I use a Telerik component (radGrid) to show/edit/update/delete data. Now I can show entity data to user simply doing a simple (linq to entities) query like:

     var stabilimenti = from s in entities.Stabilimenti
                                   select s;

    My problem is to persist data on database when user changes them.

    In my user page i want to catch the "RadGrid1_UpdateCommand" and in some way persist data modification. Debugging i've seen that at the update event i've lost all data modification (the program executes a Page_Load just before).

    How can I persist modification? Have I to use an Entity DataSource and manually place there datas retrieved from Entity Framework entities? Or what else should I do?

  2. Tsvetoslav
    Tsvetoslav avatar
    1823 posts

    Posted 29 Apr 2010 Link to this post

    Hello Francesco,

    Attached is a small sample that demonstrates your scenario.

    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. DevCraft R3 2016 release webinar banner
Back to Top