FindStartIndexAsync | findStartIndexAsync method

StorageItemQueryResult.FindStartIndexAsync | findStartIndexAsync method

Retrieves the index of the item from the query results that most closely matches the specified property value. The property that is matched is determined by the first SortEntry of the QueryOptions.SortOrder list.

Syntax


public:
IAsyncOperation<unsigned int>^ FindStartIndexAsync(
  Object^ value
)

Parameters

value

Type: Object [JavaScript] | System.Object [.NET] | Platform::Object [C++]

The property value to match when searching the query results. The property to that is used to match this value is the property in the first SortEntry of the QueryOptions.SortOrder list.

Return value

Type: IAsyncOperation<UInt32>

When this method completes successfully it returns the index of the matched item in the query results.

Remarks

You can use this index in conjunction with Semantic Zoom to determine where the page should be zoomed in after the user selects the Semantic Zoom control. To learn about SemanticZoom in JavaScript, see Quickstart: adding SemanticZoom controls. To learn about SemanticZoom in C#/C++/VB, see Quickstart: adding SemanticZoom controls.

Examples

This example shows how to find the first item that has an album title that begins with an "R" in a set of query results that contains albums sorted by title.

No code example is currently available or this language may not be supported.

Requirements (Windows 10 device family)

Device family

Universal, introduced version 10.0.10240.0

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Storage.Search
Windows::Storage::Search [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows 10 Mobile

Namespace

Windows.Storage.Search
Windows::Storage::Search [C++]

Metadata

Windows.winmd

See also

StorageItemQueryResult

 

 

Show:
© 2016 Microsoft