StorageFolderQueryResult.GetFoldersAsync() | getFoldersAsync() method

Applies to Windows only

Retrieves a list of all the folders (or file groups) in the result set.

Syntax


storageFolderQueryResult.getFoldersAsync().done( /* Your success and error handlers */ );

Parameters

This method has no parameters.

Return value

Type: IAsyncOperation<IVectorView>

When this method completes successfully, it returns a list (type IVectorView) of folders or file groups that are represented by storageFolder objects. Each of these folder or file group can also be enumerated to retrieve its contents.

Examples

Use the then or done method to capture and process the list of storageFolder objects that is returned by this method, as shown in the following example.


storageFolderQueryResults.getFoldersAsync().then(
    function (folders) {
        folders.forEach(
            function (folder) {
                // Process folder
            }
        ); 
    }
);

Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

None supported

Namespace

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

Metadata

Windows.winmd

See also

storageFolderQueryResult class
storageFolderQueryResult.getFoldersAsync(startIndex, maxNumberOfItems) method
Windows.Foundation.Collections.IVectorView interface

 

 

Show:
© 2014 Microsoft