Skip to Content
avatar image
Former Member

script through interative report info??

hi

i had developed an interactive report,from 1 list it moves to list 2,now at 2 list,i want to print the data on script.i had used at line-selection for list 1 data & list 2 data,currently my script coming but through at line selection,its not working on user-commnad.i had set pf status,but my print button is not working there.my code is below:

at line-selection.

case sy-lsind.

when 1.

clear:itab2,itab2[].

do.

READ LINE SY-INDEX FIELD VALUE ch.

IF SY-SUBRC NE 0.

EXIT.

ENDIF.

IF ch eq 'X'.

MOVE itab-MATNR TO ITab2-MATNR.

MOVE itab-werks TO ITab2-werks.

MOVE itab-CHARG TO ITab2-CHARG.

MOVE itab-menge TO ITab2-menge.

MOVE ITab-EXNUM TO ITab2-EXNUM.

MOVE ITab-EXYEAR TO ITab2-EXYEAR.

MOVE ITab-EXGRP TO ITab2-EXGRP.

MOVE ITab-EXBAS TO ITab2-EXBAS.

MOVE ITab-EXBED TO ITab2-EXBED.

MOVE ITab-ECS TO ITab2-ECS.

MOVE ITab-EXADDTAX1 TO ITab2-EXADDTAX1.

MOVE ITab-exdat TO ITab2-exdat.

MOVE ITab-total TO ITab2-total.

APPEND ITab2.

CLEAR:itab,itab2.

endif.

enddo.

perform display2.

when 2.

break-point.

case sy-ucomm.

when 'PRNT'.

perform script.

endcase.

endcase.

in perform display2,i had set pf status,but nothing happening on PRINT button.

plz tell how to slove this.

regds

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Aug 16, 2008 at 11:44 AM

    i have modified ur code little.check after perform display2.u keep pf status in display2 itself.

    i have ended case of lsind.

    and started new event at user-command.

    check this out.

    at line-selection.

    case sy-lsind.

    when 1.

    clear:itab2,itab2[].

    do.

    READ LINE SY-INDEX FIELD VALUE ch.

    IF SY-SUBRC NE 0.

    EXIT.

    ENDIF.

    IF ch eq 'X'.

    MOVE itab-MATNR TO ITab2-MATNR.

    MOVE itab-werks TO ITab2-werks.

    MOVE itab-CHARG TO ITab2-CHARG.

    MOVE itab-menge TO ITab2-menge.

    MOVE ITab-EXNUM TO ITab2-EXNUM.

    MOVE ITab-EXYEAR TO ITab2-EXYEAR.

    MOVE ITab-EXGRP TO ITab2-EXGRP.

    MOVE ITab-EXBAS TO ITab2-EXBAS.

    MOVE ITab-EXBED TO ITab2-EXBED.

    MOVE ITab-ECS TO ITab2-ECS.

    MOVE ITab-EXADDTAX1 TO ITab2-EXADDTAX1.

    MOVE ITab-exdat TO ITab2-exdat.

    MOVE ITab-total TO ITab2-total.

    APPEND ITab2.

    CLEAR:itab,itab2.

    endif.

    enddo.

    perform display2.

    endcase.

    at user-command.

    case sy-ucomm.

    when 'PRNT'.

    perform script.

    endcase.

    Add comment
    10|10000 characters needed characters exceeded