SHEnumerateUnreadMailAccounts function
Enumerates the user accounts that have unread email.
Syntax
HRESULT SHEnumerateUnreadMailAccounts(
_In_opt_ HKEY hKeyUser,
DWORD dwIndex,
_Out_ LPTSTR pszMailAddress,
int cchMailAddress
);
Parameters
- hKeyUser [in, optional]
-
Type: HKEY
A valid HKEY for a given user.
- dwIndex
-
Type: DWORD
The index of the user account.
- pszMailAddress [out]
-
Type: LPTSTR
A pointer to a Unicode string that specifies the email address of an account belonging to the specified user.
- cchMailAddress
-
Type: int
The number of characters in the email address.
Return value
Type: HRESULT
If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
The hKeyUser parameter is the HKEY for the root of the user's information, for example HKEY_CURRENT_USER, or any key enumerated under HKEY_USERS.
Requirements
|
Minimum supported client |
Windows XP [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2003 [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|
|
Unicode and ANSI names |
SHEnumerateUnreadMailAccountsW (Unicode) and SHEnumerateUnreadMailAccountsA (ANSI) |