User.GetPropertiesAsync(IVectorView<String>) 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.
Gets properties for the user.
public:
virtual IAsyncOperation<IPropertySet ^> ^ GetPropertiesAsync(IVectorView<Platform::String ^> ^ values) = GetPropertiesAsync;
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncOperation<IPropertySet> GetPropertiesAsync(IVectorView<winrt::hstring> const& values);
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncOperation<IPropertySet> GetPropertiesAsync(IReadOnlyList<string> values);
function getPropertiesAsync(values)
Public Function GetPropertiesAsync (values As IReadOnlyList(Of String)) As IAsyncOperation(Of IPropertySet)
Parameters
- values
-
IVectorView<Platform::String>
IVectorView<winrt::hstring>
The properties to get. Use the KnownUserProperties class to obtain property names.
Returns
When this method completes, it returns the requested properties. If a property is missing or unavailable, it is reported as an empty string.
- Attributes
Windows requirements
App capabilities |
userAccountInformation
|
Remarks
Not all properties are available for all users. The following table summarizes which properties are available under various conditions.
Property | Local account not domain joined | Local account domain joined | MSA account | AAD account |
---|---|---|---|---|
AccountName | Not available | Not available | Not available | Not available |
DisplayName | Not available | Not available | Not available | Available if domain joined |
DomainName | Not available | Available | Not available | Available |
FirstName | Available | Available | Available | Available |
GuestHost | Available on XBOX | Available on XBOX | Available on XBOX | Available on XBOX |
LastName | Available | Available | Available | Available |
PrincipalName | Not available | Available | Not available | Available if domain joined |
ProviderName | Not available | Not available | Not available | Not available |
SessionInitiationProtocolUri | Not available | Available | Not available | Available if domain joined |