Finds the next descendant of parentElement with the specified tag
public Leadtools.Dicom.DicomElement FindNextDescendant(
Leadtools.Dicom.DicomElement parentElement,
Leadtools.Dicom.DicomElement childElement,
bool nextLevelOnly
)
Public Function FindNextDescendant( _
ByVal parentElement As Leadtools.Dicom.DicomElement, _
ByVal childElement As Leadtools.Dicom.DicomElement, _
ByVal nextLevelOnly As Boolean _
) As Leadtools.Dicom.DicomElement
public:
Leadtools.Dicom.DicomElement^ FindNextDescendant(
Leadtools.Dicom.DicomElement^ parentElement,
Leadtools.Dicom.DicomElement^ childElement,
bool nextLevelOnly
)
parentElement
a parent item in the Data Set.
childElement
a child item of the parentElement
nextLevelOnly
if set to true
search for items in the next level only; otherwise search for items recursively in all the next levels.
The next item in the Data Set with a specific, or a null reference (Nothing in VB) if an item with the specified Tag was not found.
Note: This function does not specify a tag to use when searching. However the tag that was used in the last call to FindFirstDescendant is used by default when searching.
This method finds the next descendant of the parentElement element that has a DICOM tag equivalent to the tag argument (FindFirstDescendant), where the entire search is rooted at the Parent element (i.e. parentElement).
The diagram below represents DICOM elements stored in a DICOM dataset.
Behavior when nextLevelOnly is true
Returns the next element on the next level of parentElement with that has a tag equivalent to the tag argument in the previous call of FindFirstDescendant. Elements included in the search include child elements in the next level only.
Example 1
nextLevelOnly is true
parentElement points to element 1
childElement points to element 8
Searches elements 11, 12 and returns the first element that matches the tag argument used in the previous call to FindFirstDescendant.
Example 2 nextLevelOnly is true
parentElement points to element 2
childElement points to element 3
Searches elements 4, 7 and returns the first element that matches the tag argument used in the previous call to FindFirstDescendant.
Example 3
nextLevelOnly is true
parentElement points to element 4
childElement points to element 5
Searches element 6 only, and returns element 6 if it has a tag equivalent to the tag argument used in the previous call to FindFirstDescendant.
Example 4
nextLevelOnly is true
parentElement points to element 11
childElement points to element 12
Returns null
Behavior when nextLevelOnly is false
:
Returns the next element that matches the tag argument used in the previous call to FindFirstDescendant, using a pre-order search algorithm rooted at parentElement.
Example 5
nextLevelOnly is false
parentElement points to element 1
childElement points to element 4
Searches elements 5, 6, 7, 8, 9, 10, 11, 12 and returns the first element that has a tag equivalent to the tag argument used in the previous call to FindFirstDescendant.
Example 6
nextLevelOnly is false
parentElement points to element 2
childElement points to element 4
Searches elements 5, 6, 7 and returns the first element that has a tag equivalent to the tag argument used in the previous call to FindFirstDescendant.
Example 7
nextLevelOnly is false
parentElement points to element 4
childElement points to element 5
Searches element 6 only, and returns element 6 if is has a tag equivalent to the tag argument used in the previous call to FindFirstDescendant.
The following methods will also help you find elements in the Data Set with a specific Tag:
The following methods will help you find specific modules in the Data Set:
For an example, refer to FindFirstDescendant.
![]() |
Products |
Support |
Feedback: FindNextDescendant Method - Leadtools.Dicom |
Introduction |
Help Version 19.0.2017.6.16
|
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.