cancel
Showing results for 
Search instead for 
Did you mean: 

IT0128

Former Member
0 Kudos

Gurus

How to download SUBTYPE2 Tdline from IT128

Edited by: CPU2011 on Jan 6, 2011 10:45 AM

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi there,

1) read infotype 0128


  DATA: it_0128 TYPE STANDARD TABLE OF p0128.

  CALL FUNCTION 'HR_READ_INFOTYPE'
    EXPORTING
      pernr     = pernr-pernr
      infty     = '0128'
      begda     = sy-datum
      endda     = sy-datum
    TABLES
      infty_tab = it_0128.
  
  DELETE TABLE it_0128 WITH KEY subty NE '2'.

2) transform from the txtid to the real text-line


  DATA: it_line TYPE STANDARD TABLE OF tline,

    CALL FUNCTION 'READ_TEXT'
      EXPORTING
        id       = lw_0128-txtid
        language = lw_0128-sprsl
        name     = lw_0128-obnam
        object   = lw_0128-objct
      TABLES
        lines    = it_line.

3) Loop over it_line


  DATA: wa_line TYPE tline.

  LOOP at it_line into wa_line.
    WRITE: / wa_line-tdline.
  ENDLOOP.

Answers (0)