MoveFirstKey method

Delphi Example

C++ Builder Example

 

Builder Syntax

int __fastcall MoveFirstKey (bool bTree);

Delphi Syntax

Function MoveFirstKey (bTree: Boolean): Integer;

Overview

Refer to Working with Key Elements.

Remarks

Updates the CurrentElement property to the first key element in the DICOM Dir Data Set. The result depends on whether the DICOM Dir Data Set is evaluated as a list or a tree.

If the DICOM Dir Data Set is evaluated as a tree structure, this method updates the CurrentElement property with the first key element on the same level and with the same parent as the key element contained in the CurrentElement property. Please note that the numbering of the items in this first illustration is arbitrary and does not imply order.

image\GetFstTr.gif

 

If the CurrentElement property contains:

The CurrentElement property will be updated with:

Item 1

Item 2

Item 3

Item 4

Item 5

Item 5

Item 6

Item 7

NULL

Item 2

If the DICOM Dir Data Set is evaluated as a list, the CurrentElement property is updated with the first key element in the list. Please note that the numbering of the items in this illustration does indicate the order of the items when the DICOM Dir Data Set is evaluated as a list.

image\GetFtLst.gif

 

If the CurrentElement property contains:

The CurrentElement property will be updated with:

NULL

Item 1

Item 12

Item 1

Item 14

Item 1

Item 22

Item 1

Item 25

Item 1

The following methods will also help you navigate the DICOM Dir Data Set as either a tree or a list:

MoveLastKey method

MovePrevKey method

MoveNextKey method

If you evaluate the DICOM Dir Data Set as a tree, you can also use the following methods to navigate the tree:

MoveRootKey method

MoveParentKey method

MoveChildKey method

Note:

Visual Basic users can either check the return value of the method, or capture and process errors to determine whether the MovexxxElement methods have completed successfully.

See Also

Elements:

MoveLastKey method, MovePrevKey method, MoveNextKey method, MoveRootKey method, MoveParentKey method, MoveChildKey method