sapdev logo background
sapdev logo sapdev logo
Comments

Create Container and Object





* Add following code to 'STATUS_0100'(PBO module)
*-----------------------------------------------*
* Create tree control
PERFORM create_object_in_container.


* Add following code to 'Z......F01' INCLUDE
*-------------------------------------------*
*&-------------------------------------------------------------*
*&      Form  CREATE_OBJECT_IN_CONTAINER
*&-------------------------------------------------------------*
*       Create ALVtree control
*--------------------------------------------------------------*
FORM create_object_in_container.
  CREATE OBJECT gd_tree
    EXPORTING
        parent              = gd_custom_container
        node_selection_mode = cl_gui_simple_tree=>node_sel_mode_single
    EXCEPTIONS
        cntl_system_error            = 2
        create_error                 = 3
        lifetime_error               = 4
        illegal_node_selection_mode  = 5
        failed                       = 6.
  IF sy-subrc <> 0.
    MESSAGE x208(00) WITH 'ERROR'.
  ENDIF.
ENDFORM.



comments powered by Disqus