DataServiceCollection<T>.LoadNextPartialSetAsync Method

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Loads the next page of data into the collection.

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

Syntax

'Declaration
Public Function LoadNextPartialSetAsync As Boolean
public bool LoadNextPartialSetAsync()

Return Value

Type: System.Boolean
A Boolean value that is true when the DataServiceCollection<T> has a continuation token; otherwise false.

Remarks

The LoadNextPartialSetAsync method only returns true and loads the next page of data when paging is enabled in the data service and when a continuation token can be accessed from the Continuation property. When the Continuation property is nulla null reference (Nothing in Visual Basic), a request is not sent to the data service. For more information, see How to: Create the Northwind Data Service (WCF Data Services/Silverlight).

Because the LoadNextPartialSetAsync method is asynchronous, the method returns before a response to the data service is received. You must handle the LoadCompleted event to access the QueryOperationResponse<T> that contains information about the result of the load operation. Items are loaded into the collection when the load operation is complete, whether or not the LoadCompleted event is handled.

The LoadNextPartialSetAsync method can be called only once on the UI thread. The method cannot be called again until after the LoadCompleted event is raised. The LoadCompleted event is raised whether or not the query succeeds.

Version Information

Silverlight

Supported in: 5, 4

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.