Information
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::AddObject Method (String^, Object^)

Entity Framework 6.0
 

Adds an object to the object context.

Namespace:   System.Data.Entity.Core.Objects
Assembly:  EntityFramework (in EntityFramework.dll)

public:
virtual void AddObject(
	String^ entitySetName,
	Object^ entity
)

Parameters

entitySetName
Type: System::String^

Represents the entity set name, which may optionally be qualified by the entity container name.

entity
Type: System::Object^

The Object to add.

Exception Condition
ArgumentNullException

The entity parameter is null or the entitySetName does not qualify.

Return to top
Show: