The IDLffDICOM::GetParent function method is used to find the parent references of a set of elements in a DICOM sequence.
Result = Obj->[IDLffDICOM::]GetParent(ReferenceList)
Returns the parent references of a set of elements in a DICOM sequence. It takes as an argument an array of references that represent DICOM elements. If no members of the ReferenceList are members of a sequence, a -1 is returned, and for each member of the ReferenceList which is not a member of a sequence, a -1 is returned.
An array of references to DICOM elements that are known to be members of a DICOM sequence.
obj = OBJ_NEW('IDLffDICOM') read = obj->Read(DIALOG_PICKFILE(FILTER = '*')) ; Get the reference to the Referenced Study Sequence ; element, if it exists: ref = obj->GetReference('0008'x, '1110'x) PRINT, ref PRINT, obj->GetDescription(REFERENCE = ref) ; Get and print the parent sequence, if it exists. ; This should result in a -1 since this element is not ; a member of a sequence: parent = obj->GetParent(ref) PRINT, parent PRINT, obj->GetDescription(REFERENCE=parent) ; Get the children of the Referenced Study Sequence ; element, if it exists: refs = obj->GetChildren(ref) PRINT, refs PRINT, obj->GetDescription(REFERENCE = refs) OBJ_DESTROY, obj