Share via


CSid::AccountName

Returns the name of the account associated with the CSid object.

LPCTSTR AccountName( ) const throw(...);

Return Value

Returns the LPCTSTR pointing to the name of the account.

Remarks

This method attempts to find a name for the specified SID (security identifier). For full details, see LookupAccountSid.

If no account name for the SID can be found, AccountName returns an empty string. This can occur if a network timeout prevents this method from finding the name. It also occurs for security identifiers with no corresponding account name, such as a logon SID that identifies a logon session.

Requirements

Header: atlsecurity.h

See Also

Reference

CSid Class

CSid::Domain

LookupAccountSid

Other Resources

CSid Members