TryGetObjectByKey... empty ObjectSets
Posted
by Rickjaah
on Stack Overflow
See other posts from Stack Overflow
or by Rickjaah
Published on 2010-04-26T14:14:07Z
Indexed on
2010/04/26
14:43 UTC
Read the original article
Hit count: 437
When I use TryGetObjectByKey on my ObjectContext, it returns an error. An item with a duplicate value already exists.
When I look at my objectContext, I see that the ObjectSets are empty. What Am I doing wrong... When I enumerate the ObjectSet by hand, by using ToArray on it, or by using the debugger, it does work.
LazyLoadingEnabled = true.
I reuse 2 tables from another EDMX, but they are in different namespaces and they are not the objectSets i try to approach.
© Stack Overflow or respective owner