The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.
ObjectContext::GetObjectByKey Method (EntityKey^)
Entity Framework 6.0
Returns an object that has the specified entity key.
Assembly: EntityFramework (in EntityFramework.dll)
Parameters
- key
-
Type:
System.Data.Entity.Core::EntityKey^
The key of the object to be found.
| Exception | Condition |
|---|---|
| ArgumentNullException | The key parameter is null. |
| ObjectNotFoundException | The object is not found in either the ObjectStateManager or the data source. |
Show: