0% found this document useful (0 votes)
9 views

Program

This document contains the code for an ABAP program that displays customer and purchase order details. It defines two internal tables to store customer and purchase order data extracted from database tables. It also contains the module codes to handle user commands to display, exit, and list the data on different screens.

Uploaded by

alisnowkiss
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Program

This document contains the code for an ABAP program that displays customer and purchase order details. It defines two internal tables to store customer and purchase order data extracted from database tables. It also contains the module codes to handle user commands to display, exit, and list the data on different screens.

Uploaded by

alisnowkiss
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

program

zmod111 no standard page heading.

tables : kna1 , vbak .


controls : tstrip type tabstrip,
tcontrol type tableview using screen 120.
data : begin of itab occurs 10,
land1
name1
ort01
regio
telf1
telfx

type
type
type
type
type
type

kna1-land1,
kna1-name1,
kna1-ort01,
kna1-regio,
kna1-telf1,
kna1-telfx,

end of itab.

data : begin of jtab occurs 10,


vbeln type vbak-vbeln,
erdat type vbak-erdat,
netwr type vbak-netwr,
end of jtab.
*
*
CALL SCREEN 100.
*
CALL SCREEN 110.
*
CALL SCREEN 120.
*&---------------------------------------------------------------------*
*&
Module USER_COMMAND_0100 INPUT
*&---------------------------------------------------------------------*
*
text
*----------------------------------------------------------------------*
module user_command_0100 input.
case sy-ucomm.
when 'DISP'.
select land1 name1 ort01 regio telf1 telfx
into itab
from kna1
where kunnr = kna1-kunnr.
append itab.
endselect.
select vbeln erdat netwr
from vbak
into table jtab
where kunnr = kna1-kunnr.

when 'EXIT'.
leave program .

when 'LIST'.
leave to list-processing.
format color 5.
write : / 'PURCHASE ORDER DETAILS'.
loop at jtab.
format color 3 inverse.
write: / jtab-vbeln , jtab-erdat , jtab-netwr.
endloop.
endcase.
endmodule.
" USER_COMMAND_0100 INPUT
*&---------------------------------------------------------------------*
*&
Module STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
*
text
*----------------------------------------------------------------------*
module status_0110 output.
* SET PF-STATUS 'xxxxxxxx'.
* SET TITLEBAR 'xxx'.
move-corresponding itab to kna1.
endmodule.
" STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
*&
Module STATUS_0120 OUTPUT
*&---------------------------------------------------------------------*
*
text
*----------------------------------------------------------------------*
module status_0120 output.
* SET PF-STATUS 'xxxxxxxx'.
* SET TITLEBAR 'xxx'.
move-corresponding jtab to vbak.
endmodule.

" STATUS_0120

OUTPUT

You might also like