ImageGear for C and C++ on Windows v20.5 - Updated
IG_ISIS_drv_update_state
API Reference Guide > ISIS Component API Reference > ISIS Component Functions Reference > Tag Functions > IG_ISIS_drv_update_state

Update the values of dependent values in a dialog box.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI IG_ISIS_drv_update_state(
        HISISDRV hDriver,
        AT_MODE nTag,
        WORD wIndex
);

Arguments:

Name Type Description
hDriver HISISDRV The handle of the driver on which tags choices need to be changed. This is a pointer to the handle of the PIXFPACK driver.
nTag AT_MODE The tag value which is being changed. Usually, this value will be one of IG_ISIS_TAG_FILETYPE_LBS and IG_ISIS_TAG_COLORFMTS_LBS (if you are using one color format list box), or one of IG_ISIS_TAG_FILETYPE_LBS, IG_ISIS_TAG_SPP_LBS, IG_ISIS_TAG_BPS_LBS, and IG_ISIS_TAG_PHOTO_LBS (if you are using three separate list boxes to establish color formats.
wIndex WORD The index number of the new value of nTag.

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.

Remarks:

The IG_ISIS_drv_update_state function checks the value of an interdependent tag and then updates choices for dependent tags, allowing an application to update the values being displayed in a dialog box dynamically as the user picks various file and color formats. By using this function with Custom Dialog tags, you can create an application that can save files in whatever formats are currently supported by the file converters (*.PXIs) installed on the system. Using this function together with the Custom Dialog tags allows you to design an application which will automatically add new file types to a list box whenever the user installs new file converters.

The IG_ISIS_drv_update_state function signals PIXFPACK to update the choices of dependent tags. This is used to update the values of Color Format and Compression when File Type is changed, and to update the values of Compression when Color Format is changed.

To use IG_ISIS_drv_update_state, monitor a list box for a change. If the File Format list box gets changed, first get the current values of the dependent tags, then call IG_ISIS_drv_update_state with nTag set to IG_ISIS_TAG_FILETYPE_LBS and wIndex set to the new index value of the selected file type. IG_ISIS_drv_update_state will update the choices reported by IG_ISIS_TAG_COLORFMTS_LBS and IG_ISIS_TAG_COMPRESSION_LBS. Your application should then compare the new values of each of the dependent tags with the previous values and, if there is a match, keep the setting the same. If there is no match, you must decide on a new setting.

You will need to use IG_ISIS_drv_update_state while monitoring each of the listboxes that set tags that have dependencies. The following dependencies exist:

Is this page helpful?
Yes No
Thanks for your feedback.