Properties | SourceCde
Title |  |
Original language | DE | Englisch
Created | 27.10.1998 |  | SAP |
Last changed by | 13.11.2001 |  | SAP |
Status | Active |
Attributes
Type | INCLUDE program |
Status | Test program |
Application | Basis |
Package | SVIM | Basis View Maintenance
| Editor lock
txt
    1
    *---------------------------------------------------------------------*
    2
    *       FORM VIM_SINGLE_ENTRY_FILL_SELLIST                            *
    3
    *---------------------------------------------------------------------*
    4
    * fill sellist in case of single entry maintenance                    *
    5
    *---------------------------------------------------------------------*
    6
    FORM vim_single_entry_fill_sellist.
    7
      DATA: countx TYPE i, nam_ix TYPE i.
    8
      FIELD-SYMBOLS: <h1>.
    9
    10
      LOOP AT x_namtab WHERE keyflag NE space AND texttabfld EQ space.
    11
        CHECK x_header-clidep EQ space OR sy-tabix GT 1.
    12
        nam_ix = sy-tabix.
    13
        assign component x_namtab-viewfield of structure <table1> to <h1>.
    14
    *    ASSIGN <TABLE1>+X_NAMTAB-POSITION(X_NAMTAB-FLENGTH) TO <H1>.
    15
        READ TABLE dpl_sellist WITH KEY viewfield = x_namtab-viewfield
    16
                                        operator  = 'EQ'
    17
                                        negation  = space.
    18
        IF sy-subrc NE 0.
    19
          CLEAR dpl_sellist.
    20
          dpl_sellist-viewfield = x_namtab-viewfield.
    21
          dpl_sellist-operator  = 'EQ'.
    22
          dpl_sellist-and_or    = 'AND'.
    23
          dpl_sellist-tabix     = nam_ix.
    24
          APPEND dpl_sellist.
    25
        ENDIF.
    26
        countx = sy-tabix. CLEAR dpl_sellist-converted.
    27
        dpl_sellist-ddic = 'S'. CLEAR dpl_sellist-value.
    28
        CALL FUNCTION 'VIEW_CONVERSION_OUTPUT'
    29
             EXPORTING
    30
                  value_intern = <h1>
    31
                  tabname      = x_header-maintview
    32
                  fieldname    = x_namtab-viewfield
    33
    *              inttype      = x_namtab-inttype
    34
    *              datatype     = x_namtab-datatype
    35
    *              decimals     = x_namtab-decimals
    36
    *              convexit     = x_namtab-convexit
    37
    *              sign         = x_namtab-sign
    38
                  outputlen    = x_namtab-outputlen
    39
                  intlen       = x_namtab-flength
    40
             IMPORTING
    41
                  value_extern = dpl_sellist-value.
    42
        IF dpl_sellist-value EQ space.
    43
          dpl_sellist-initial = 'X'.
    44
        ELSE.
    45
          CLEAR dpl_sellist-initial.
    46
        ENDIF.
    47
        MODIFY dpl_sellist INDEX countx.
    48
        x_namtab-readonly = 'S'. MODIFY x_namtab.
    49
      ENDLOOP.
    50
      ASSIGN dpl_sellist[] TO <vim_ck_sellist>.
    51
      x_header-subsetflag = x_header-selection = 'X'.
    52
      MODIFY x_header INDEX 1.
    53
      PERFORM init_subset_keyfields.
    54
    ENDFORM.                               "vim_single_entry_fill_sellist