Share via


WcsEnumColorProfiles

Enumerates all color profiles that satisfy the enumeration criteria in the specified profile management scope.

BOOL WINAPI WcsEnumColorProfiles(
   __in WCS_PROFILE_MANAGEMENT_SCOPEprofileManagementScope,
   __in PENUMTYPEWpEnumRecord,
   __out_bcount(dwSize) PBYTEpBuffer,
   __in DWORDdwSize,
  __out_opt PDWORDpnProfiles);

Parameters

  • profileManagementScope
    A WCS_PROFILE_MANAGEMENT_SCOPE value specifying the scope of this profile management operation.
  • pEnumRecord
    A pointer to a structure specifying the enumeration criteria.
  • pBuffer
    A pointer to a buffer in which the profile names are to be enumerated. The WcsEnumColorProfiles function places, in this buffer, a MULTI_SZ string that consists of profile names that satisfy the criteria specified in *pEnumRecord.
  • dwSize
    A variable that contains the size, in bytes, of the buffer that is pointed to by pBuffer. See Remarks.
  • pnProfiles
    An optional pointer to a variable that receives the number of profile names that are copied to the buffer to which pBuffer points. Can be NULL if this information is not needed.

Return Values

If this function succeeds, the return value is TRUE.

If this function fails, the return value is FALSE. For extended error information, call GetLastError.

Remarks

Use the WcsEnumColorProfilesSize function to retrieve the value for the dwSize parameter, which is the size, in bytes, of the buffer pointed to by the pBuffer parameter.

If the profileManagementScope parameter is WCS_PROFILE_MANAGEMENT_SCOPE_SYSTEM_WIDE, only system-wide associations of profiles to the device are considered. If profileManagementScope is WCS_PROFILE_MANAGEMENT_SCOPE_CURRENT_USER, only per-user associations for the current user are considered. If WcsSetUsePerUserProfiles has never been called for this user, or if WcsSetUsePerUserProfiles was most recently called for this user with its usePerUserProfiles parameter set to FALSE, then WCSEnumColorProfiles returns an empty list.

If WCS_PROFILE_MANAGEMENT_SCOPE_CURRENT_USER (the current user setting) is present, it overrides the system-wide default for the profileManagementScope parameter.

This function is executable in Least-Privileged User Account (LUA) context.

Requirements

**  Windows Vista:** Included in Windows Vista and later.
**  Header:** Declared in Icm.h.
**  Library:** Use Mscms.lib.
**  Unicode:** Implemented as Unicode and ANSI versions on Windows Vista.

See Also

Basic Color Management Concepts, Windows Color System Schemas and Algorithms, Functions, WCS_PROFILE_MANAGEMENT_SCOPE, WcsEnumColorProfilesSize