Code: Alles auswählen.
lr_level = gr_hierseq->get_level.( 1 )
lr_level->set_items_expanded( ).
Code: Alles auswählen.
DATA: lt_expanded_nodes TYPE lvc_t_nkey.
CALL METHOD tree->get_expanded_nodes
CHANGING
ct_expanded_nodes = lt_expanded_nodes
EXCEPTIONS
cntl_system_error = 1
dp_error = 2
failed = 3
OTHERS = 4.
IF sy-subrc <> 0.
"Message
ENDIF.
Code: Alles auswählen.
IF lt_expanded_nodes IS INITIAL.
CALL METHOD tree->expand_node
EXPORTING
i_node_key = gv_relat
* i_level_count = 1
* i_expand_subtree =
EXCEPTIONS
failed = 1
illegal_level_count = 2
cntl_system_error = 3
node_not_found = 4
cannot_expand_leaf = 5
OTHERS = 6.
IF sy-subrc <> 0.
" Message
ENDIF.
ELSE.
CALL METHOD tree->collapse_all_nodes
EXCEPTIONS
failed = 1
cntl_system_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
" Message
ENDIF.