Admin Production ni-theme
Current Publication

ColorPicker_GetActiveColorCell

LabWindows/CVI

ColorPicker_GetActiveColorCell

int ColorPicker_GetActiveColorCell (int panel, int control, int *index, int *type);

Purpose

Obtains the index and type of the active color cell.

Parameters

Input
Name Type Description
panel int The specifier for a particular panel that is currently in memory. You obtain this handle from LoadPanel, NewPanel, or DuplicatePanel.
control int The ID you specified as the canvas parameter in the ColorPicker_Convert function call. This value must be the same as the defined constant, located in the .uir header file, that you assigned to the original canvas control.
Output
Name Type Description
index int The zero-based index of the active color cell or PICKER_VAL_TRANSPARENT if the active item is the transparent item.
type int The type of cell that is currently active. Valid values are PICKER_VAL_FIXED_COLOR, PICKER_VAL_CUSTOM_COLOR, and PICKER_VAL_TRANSPARENT.

Return Value

Name Type Description
status int Return value indicating whether the function was successful. A negative number indicates that an error occurred.

Additional Information

Library: Color Picker Control

Include file: custctrl\color_picker.h

LabWindows/CVI compatibility: LabWindows/CVI 9.0 and later

Examples

Refer to the following examples that use the ColorPicker_GetActiveColorCell function:

  • apps\iconedit\iconedit.cws

    Open example
  • userint\custctrl\colorpicker\colorpickerdemo.cws

    Open example