This routine is obsolete and should not be used in ENVI application programming interface (API) code.

This procedure returns or sets the value of an existing handle.





Specify a valid handle ID.


When using HANDLE_VALUE to return an existing handle value (the default), Value is a named variable in which the value is returned.

When using HANDLE_VALUE to set a handle value, Value is the new value. Note that handle values can have any IDL data type and organization.



By default, HANDLE_VALUE works by making a second copy of the source data. Although this technique is fine for small data, it can have a significant memory cost when the data being copied are large.

If you set this keyword, HANDLE_VALUE works differently. Rather than copy the source data, it takes the data away from the source and attaches them directly to the destination. This feature can be used to move data very efficiently. However, it can cause the source variable to become undefined. On a retrieve operation, the handle value becomes undefined. On a set operation, the variable passed as Value becomes undefined.


Set this keyword to assign Value as the new handle value. The default is to retrieve the current handle value.


The following commands demonstrate the two different uses of HANDLE_VALUE:

; Retrieve the value of handle1 into the variable current.
HANDLE_VALUE, handle1, current
; Set the value of handle1 to a 2-element integer vector.