MoveRootElement method
Builder Syntax |
int __fastcall MoveRootElement(void); |
Delphi Syntax |
function MoveRootElement: Integer; |
Overview |
Refer to Working with Data Sets. |
Remarks
Updates the CurrentElement property to the root of the item specified in the CurrentElement property.
The root is the Level 0 ancestor of the item specified in the CurrentElement property. If the CurrentElement property specifies an item on Level 0, the CurrentElement property will be updated with the same item . Please note that the numbering of the items in this illustration is arbitrary and does not imply order.
If the CurrentElement property contains: |
The CurrentElement property will be updated with: |
Item 1 |
Item 2 |
Item 3 |
Item 2 |
Item 4 |
Item4 |
Item 5 |
Item 6 |
The following methods will also help you navigate the Data Set:
Note: You can either check the return value of the method, or capture and process errors to determine whether the MovexxxElement methods have completed successfully. For an example of capturing errors, refer to any of the MovexxxElement method examples.
See Also
Elements: |
MoveFirstElement method, MoveLastElement method, MoveNextElement method, MovePrevElement method, MoveParentElement method, MoveChildElement method |