DataServiceContext.BeginLoadProperty Method (Object, String, AsyncCallback, Object)

Asynchronously loads the value of the specified property from the data service.

Namespace:  System.Data.Services.Client
Assembly:  Microsoft.Data.Services.Client (in Microsoft.Data.Services.Client.dll)

public IAsyncResult BeginLoadProperty(
	Object entity,
	string propertyName,
	AsyncCallback callback,
	Object state


Type: System.Object
The entity that contains the property to load.
Type: System.String
The name of the property on the specified entity to load.
Type: System.AsyncCallback
The delegate called when a response to the request is received.
Type: System.Object
The user-defined state object that is used to pass context data to the callback method.

Return Value

Type: System.IAsyncResult
An IAsyncResult that represents the status of the asynchronous operation.

Calling this method invokes a network operation to retrieve the value of a property. The property specified may be any one of the properties on an entity, including properties which represent associations or links. If the property represents an association or link or a deferred property, calling this method provides the client with a way to lazily load related resources. If the entity is in the modified state, the property value loads related entities and marks them and any links as unchanged.

If the property is already loaded, calling this method lets you refresh the value of the property.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
© 2015 Microsoft