Sdílet prostřednictvím


KnownFolders.GetFolderForUserAsync(User, KnownFolderId) Method

Definition

Static method that returns a specified known folder for a User.

public:
 static IAsyncOperation<StorageFolder ^> ^ GetFolderForUserAsync(User ^ user, KnownFolderId folderId);
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<StorageFolder> GetFolderForUserAsync(User const& user, KnownFolderId const& folderId);
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<StorageFolder> GetFolderForUserAsync(User user, KnownFolderId folderId);
function getFolderForUserAsync(user, folderId)
Public Shared Function GetFolderForUserAsync (user As User, folderId As KnownFolderId) As IAsyncOperation(Of StorageFolder)

Parameters

user
User

The User for which the folder is returned.

folderId
KnownFolderId

The ID of the folder to be returned.

Returns

When this method completes, it returns the requested StorageFolder object.

Attributes

Windows requirements

Device family
Windows 10 (introduced in 10.0.10586.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v2.0)

Applies to

See also