ALV Sample Code
Hi friends,
I would like to set up list through ALV grid control.
Can any body send me simple sample program.
Thanks in advance.
Reply : Subject: ALV Sample Code
Hello,
here I am sending you sample program for alv
========================================
Report ZHELLO.
Tables:
MAKT,
MARA.
data: begin of itab_alv1 occurs
10,
MAKTX like MAKT-MAKTX ,
MATFI like MARA-MATFI ,
MATNR like MARA-MATNR ,
MFRPN like MARA-MFRPN ,
END OF ITAB_ALV1.
type-pools: slis.
data: afield type slis_fieldcat_alv.
DATA: fieldcat type slis_t_fieldcat_alv.
clear afield.
afield-col_pos = 1 .
afield-fieldname = 'MAKTX'.
afield-seltext = ''.
append afield to fieldcat.
afield-col_pos = 2 .
afield-fieldname = 'MATFI'.
afield-seltext = ''.
append afield to fieldcat.
select * from mara.
select * from makt
where
matnr = mara-matnr.
itab_alv1-matnr = mara-matnr.
itab_alv1-maktx = makt-maktx.
append itab_alv1.
endselect.
endselect.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
IT_FIELDCAT = fieldcat
Tables
t_outtab = itab_alv1.
Reply : Subject: ALV Sample Code
thanks.........
More Function Module
Functions / SAP
Script / ALV
Tables
Database Table
ABAP Books List
ABAP/4 Certification,
Programming, Smartforms, Sapscripts and Object Oriented Programming Books
Smart Forms
SAP Smartforms
ABAP Menu:
ABAP Example Hints
and Tips
Return to Index:-
SAP ABAP/4 Programming,
Basis Administration, Configuration Hints and Tips
(c) www.gotothings.com All material on this site is Copyright.
Every effort is made to ensure the content integrity.
Information used on this site is at your own risk.
All product names are trademarks of their respective
companies. The site www.gotothings.com is in no way affiliated with
SAP AG.
Any unauthorised copying or mirroring is prohibited.
|