ImageGear for C and C++ on Windows v19.9 - Updated
IG_ISIS_choice_get_count
API Reference Guide > ISIS Component API Reference > ISIS Component Functions Reference > Choice Functions > IG_ISIS_choice_get_count

Get the total number of legal values for a tag.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI IG_ISIS_choice_get_count(
        HISISDRV hDriver,
        AT_MODE nTag,
        LPWORD lpwCount
);

Arguments:

Name Type Description
hDriver HISISDRV The handle to the driver.
nTag AT_MODE Specifies the tag for which the count of legal choice values is being requested.
lpwCount LPWORD The address of an unsigned integer in which the number of legal values will be stored. If a choice node is defined for the tag, then this parameter will contain the available number of values in the currently-selected node. If no choice node is defined for the tag, this parameter returns a value of 1.

Return Value:

Returns the number of ImageGear errors that occurred during this function call. If there are no errors, the return value is IGE_SUCCESS.

Supported Raster Image Formats:

This function does not process image pixels.

Example:

See IG_ISIS_choice_get_ascii example.

Remarks:

The IG_ISIS_choice_get_count function retrieves the total number of legal values from a specified tag.

The IG_ISIS_choice_get_countfunction can be used to determine the valid range of the wIndex parameter to use in other IG_ISIS_choice_get... functions. The range is zero to (*lpwCount - 1).

If the tag is defined, IG_ISIS_choice_get_count always returns IGE_SUCCESS. The value returned in lpwCount is valid, and its value depends on the type of choice node for the specified tag:

IG_ISIS_choice_get_count returns the correct value even if the choices for a tag are represented as a range (low, high, step).

See Also:

IG_ISIS_choice_get_ascii

IG_ISIS_choice_get_long

IG_ISIS_choice_get_rational

IG_ISIS_tag_get_type