New Posts New Posts RSS Feed: IEntityServerSaving
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

IEntityServerSaving

 Post Reply Post Reply
Author
ehtleef View Drop Down
Newbie
Newbie


Joined: 09-Aug-2011
Posts: 4
Post Options Post Options   Quote ehtleef Quote  Post ReplyReply Direct Link To This Post Topic: IEntityServerSaving
    Posted: 11-Aug-2011 at 2:17am
Saving operation can be canceled for two reasons. 
I would like to inform user which value was incorrect and what was the reason.


Edited by ehtleef - 11-Aug-2011 at 2:18am
Back to Top
sbelini View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 13-Aug-2010
Location: Oakland
Posts: 786
Post Options Post Options   Quote sbelini Quote  Post ReplyReply Direct Link To This Post Posted: 10-Aug-2011 at 1:54pm
Hi ehtleef,
 
Unfortunatelly, you won't be able to return a custom message from a SaveChanges/SaveChangesAsync call if it's cancelled.
 
Can you explain in detail what you are trying to accomplish, so I can better understand and assist you?
 
Silvio.
Back to Top
ehtleef View Drop Down
Newbie
Newbie


Joined: 09-Aug-2011
Posts: 4
Post Options Post Options   Quote ehtleef Quote  Post ReplyReply Direct Link To This Post Posted: 10-Aug-2011 at 2:19am
Thanks,
That helped but I still have problem.
The EntityManager doesn't return entities marked (EntityState.Unchanged). 


In callback to entity.save 
in argumants there is proparty Cancelled.
Is ther any way to pass some string or int with information why save was cancelled?



Edited by ehtleef - 10-Aug-2011 at 7:32am
Back to Top
sbelini View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 13-Aug-2010
Location: Oakland
Posts: 786
Post Options Post Options   Quote sbelini Quote  Post ReplyReply Direct Link To This Post Posted: 09-Aug-2011 at 10:16am
Hi ehtleef,
 
IEntityServerSaving is not present in DevForce 2010. You might want to take a look at the EntityServerSaveInterceptor class.
 
You can find detailed information at the DevForce Resource Center.
 
Regards,
   Silvio.
Back to Top
ehtleef View Drop Down
Newbie
Newbie


Joined: 09-Aug-2011
Posts: 4
Post Options Post Options   Quote ehtleef Quote  Post ReplyReply Direct Link To This Post Posted: 09-Aug-2011 at 6:12am
Hi,
I'm trying to implement interface IEntityServerSaving 
and use it's ServerSaving event.
In my project I have referenced IdeaBlade.EntityModel.Server.

My problem is that I can't see this interface.
I can only access: IdeaBlade.EntityModel.Server.IHandlePolicy

Any ideas?
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down