AppCapability.RequestAccessForCapabilitiesForUserAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Requests access to multiple capabilities simultaneously.
public:
static IAsyncOperation<IMapView<Platform::String ^, AppCapabilityAccessStatus> ^> ^ RequestAccessForCapabilitiesForUserAsync(User ^ user, IIterable<Platform::String ^> ^ capabilityNames);
/// [Windows.Foundation.Metadata.RemoteAsync]
static IAsyncOperation<IMapView<winrt::hstring, AppCapabilityAccessStatus>> RequestAccessForCapabilitiesForUserAsync(User const& user, IIterable<winrt::hstring> const& capabilityNames);
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<IReadOnlyDictionary<string,AppCapabilityAccessStatus>> RequestAccessForCapabilitiesForUserAsync(User user, IEnumerable<string> capabilityNames);
function requestAccessForCapabilitiesForUserAsync(user, capabilityNames)
Public Shared Function RequestAccessForCapabilitiesForUserAsync (user As User, capabilityNames As IEnumerable(Of String)) As IAsyncOperation(Of IReadOnlyDictionary(Of String, AppCapabilityAccessStatus))
Parameters
- user
- User
The user property for which the object was created.
Returns
IAsyncOperation<IReadOnlyDictionary<String,AppCapabilityAccessStatus>>
IAsyncOperation<IMapView<Platform::String,AppCapabilityAccessStatus>>
IAsyncOperation<IMapView<winrt::hstring,AppCapabilityAccessStatus>>
Returns a read-only Dictionary with string capabilities as keys to AppCapabilityAccessStatus enums.
- Attributes
Remarks
RequestAccessForCapabilitiesForUserAsync does not create any new objects and can cause a user prompt to appear.
Note: Must be called from the UI thread.