The HDF_DFAN_GETLABEL procedure reads the label for the given tag-reference pair in a Hierarchical Data Format file.
fid = HDF_OPEN('test.hdf', /ALL)
tag = 105 ; The annotation tag.
ref = 2 ; Choose a reference number.
HDF_DFAN_PUTLABEL, 'test.hdf', tag, ref, label
;
Write the label.
HDF_DFAN_GETLABEL, 'test.hdf', tag, ref, outl
;
Read the label back.
HDF_DFAN_GETDESC , HDF_DFAN_LABLIST , HDF_DFAN_PUTDESC , HDF_DFAN_PUTLABEL