Programme SAP UGMD_DB_LOG_DISPLAY - Display Database Log for MDF Tables

Description
Program SAPTLIST_TREE_CONTROL_DEMO demonstrates how to use the List TreeControl (class CL_GUI_LIST_TREE).
A tree node is described by the dictionary structure TREEV_NODE. Thefield NODE_KEY contains the key of the node.
Each node of the tree can have items. An item is described by dictionarystructure TREEV_ITEM. The user of the tree control needs to extend thestructure with the character field TEXT (with an arbitrary length). Inthis sample program, TREEV_ITEM is included in structure MTREEITM inorder to add a field with the name TEXT. The field NODE_KEY determineswhich node an item belongs to. The field ITEM_NAME contains the name ofthe item. Only whole numbers starting with 1 are valid. The items of anode are output from left to right.
The example illustrates several important properties of the list treecontrol. These are explained using using several items of the example:

  • Item "Objects": This item uses a proportional font (ITEM-FONT =
  • CL_GUI_LIST_TREE=>ITEM_FONT_PROP). Using a proportional font for an itemis useful only if the width of the item is automatically adjustedaccording to the text string it contains (so that the string alwaysfits). To accomplish this, you need to type the valueCL_GUI_LIST_TREE=>ALIGN_AUTO in the ALIGNMENT field of the item.
    • The items of the third and fourth nodes from the top are used to
    • contruct a table-like structure. To do this, the first three items ofboth nodes need to have a fixed length (ITEM-ALIGNMENT =CL_GUI_LIST_TREE=>ALIGN_LEFT, ITEM-LENGTH = ...) These items require afixed-width font (ITEM-FONT = ITEM_FONT_FIXED).

      Selection
      The items of a node can be individually selected. The entire node isselected by clicking on the folder or leaf symbol of a node.
      You also can set up the selection behavior of the tree so that a clickalways selects the entire node (you initialize the ITEM_SELECTIONparameter of the constructor).

      Events
      Any events that occur are displayed in the frame at the right dynpromargin. The following events can be triggered in the sample program:

      node_dbl_clk (node doubleclick)
      A node has been double-clicked. In the example, this is achieved bydouble-clicking the folder or leaf symbol. If ITEM_SELECTION is set toSPACE, this event is fired whenever any part of the node isdouble-clicked.

      item_dbl_click (item doubleclick)
      An item of the tree has been double-clicked. This event can occur onlyif ITEM_SELECTION equals 'X'.

      expand_nc (expand no children)
      A node can have the property in which a plus sign (+) is displayed atthe folder or leaf symbol even if no child nodes exist in the control(you set the field expander in TREEV_NODE). When a user clicks on thistype of node, this fires off the event EXPAND_NC. In the example, thenode "Program" has this property. The example program reacts by sendingtwo new nodes to the control.

      button_click
      A user has clicked an item that represents a pushbutton.

      link_click
      A user has clicked an item that represents a link.