ENVINITF::GetDESUserDefinedDataValue

The GetDESUserDefinedDataValue method retrieves the value of selected Data Extension Segment (DES) user-defined data fields in a NITF file.

Example

; Start the application

e = ENVI(/HEADLESS)

 

; Open a NITF file

File = FILEPATH('DESExample.ntf', ROOT_DIR=e.ROOT_DIR, $

SUBDIRECTORY = ['data', 'NITFExamples'])

NITF = ENVINITF(File)

 

; Get the value of the ATT_TYPE of the DES

; user-defined data

Print, NITF.GetDESUserDefinedDataValue(1, 'DATE_ATT')

Result:

19700101

Syntax

Result = ENVINITF.GetDESUserDefinedDataValue(DESIndex, DESField [, ERROR=value])

Return Value

This method returns a string or string array with the values of a DES user-defined data field.

Arguments

DESIndex

Specify an integer with the index number of a DES that contains a user-defined data.

DESField

Specify a string with the DES data field name to query. Get field names using the ENVINITF::GetDESUserDefinedDataFields method.

Keywords

ERROR

Set this keyword to a named variable that will contain any error message issued during execution of this routine. If no error occurs, the ERROR variable will be set to a null string (''). If an error occurs and the routine is a function, then the function result will be undefined.

When this keyword is not set and an error occurs, ENVI returns to the caller and execution halts. In this case, the error message is contained within !ERROR_STATE and can be caught using IDL's CATCH routine. See IDL Help for more information on !ERROR_STATE and CATCH.

See Manage Errors for more information on error handling in ENVI programming.

Version History

ENVI 5.6.3

Introduced

API Version

4.2

See Also

ENVINITF, ENVINITF::GetDESUserDefinedDataFields, ENVINITF::GetSegmentValue, ENVINITF::GetDESData