TYPE-POOLS:SLIS.
TABLES:EKKO.
SELECT-OPTIONS:SO_EBELN FOR EKKO-EBELN.
DATA:BEGIN OF IT_EKKO OCCURS 0,
EBELN LIKE EKKO-EBELN, "PURCHASE DOCUMENT NUMBER
BUKRS LIKE EKKO-BUKRS, "COMPANY CODE
BSTYP LIKE EKKO-BSTYP, "PURCHASE DOCUMENT CATEGORY
BSART LIKE EKKO-BSART, "PUCHASE DOCUMENT TYPE
END OF IT_EKKO.
*FIELD CATALOG TABLE DECLARATION.
DATA:I_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV WITH HEADER LINE.
* I_EVENTCAT TYPE SLIS_T_EVENT WITH HEADER LINE.
START-OF-SELECTION.
*INTERNAL TABLE POPULATION
SELECT EBELN
BUKRS
BSTYP
BSART
FROM EKKO
INTO TABLE IT_EKKO
WHERE EBELN IN SO_EBELN.
*POPULATING FIELD CATALOG USING FIELDS IN FIELDCATALOG
*I_FIELDCAT-COL_POS = 1.
*I_FIELDCAT-FIELDNAME = 'EBELN'.
*I_FIELDCAT-TABNAME = 'IT_EKKO'.
*I_FIELDCAT-REF_FIELDNAME = 'EBELN'.
*I_FIELDCAT-REF_TABNAME = 'EKKO'.
*I_FIELDCAT-KEY = ''.
*I_FIELDCAT-EMPHASIZE = 'C510'.
**I_FIELDCAT-LOWERCASE = 'X'.
**I_FIELDCAT-SELTEXT_M = 'PURCHAGE DOCUMENT NUMBER'.
*I_FIELDCAT-OUTPUTLEN = 20.
*I_FIELDCAT-HOTSPOT = 'X'.
*I_FIELDCAT-DO_SUM = 'X'.
*APPEND I_FIELDCAT TO I_FIELDCAT.
*CLEAR I_FIELDCAT.
*
*I_FIELDCAT-COL_POS = 2.
*I_FIELDCAT-FIELDNAME = 'BUKRS'.
*I_FIELDCAT-TABNAME = 'IT_EKKO'.
*I_FIELDCAT-REF_FIELDNAME = 'BUKRS'.
*I_FIELDCAT-REF_TABNAME = 'EKKO'.
*I_FIELDCAT-KEY = ''.
*I_FIELDCAT-EMPHASIZE = 'C610'.
*I_FIELDCAT-LOWERCASE = 'X'.
**I_FIELDCAT-SELTEXT_M = 'COMPANY CODE'.
*I_FIELDCAT-OUTPUTLEN = 10.
*I_FIELDCAT-HOTSPOT = ''.
*I_FIELDCAT-DO_SUM = SPACE.
*APPEND I_FIELDCAT TO I_FIELDCAT.
*CLEAR I_FIELDCAT.
*
*I_FIELDCAT-COL_POS = 3.
*I_FIELDCAT-FIELDNAME = 'BSTYP'.
*I_FIELDCAT-TABNAME = 'IT_EKKO'.
*I_FIELDCAT-REF_FIELDNAME = 'BSTYP'.
*I_FIELDCAT-REF_TABNAME = 'EKKO'.
*I_FIELDCAT-KEY = ''.
*I_FIELDCAT-EMPHASIZE = 'C510'.
**I_FIELDCAT-LOWERCASE = 'X'.
**I_FIELDCAT-SELTEXT_M = 'DOCUMENT CATEGORY'.
*I_FIELDCAT-OUTPUTLEN = 10.
*I_FIELDCAT-HOTSPOT = 'X'.
*I_FIELDCAT-DO_SUM = SPACE.
*APPEND I_FIELDCAT TO I_FIELDCAT.
*CLEAR I_FIELDCAT.
*
*I_FIELDCAT-COL_POS = 4.
*I_FIELDCAT-FIELDNAME = 'BSART'.
*I_FIELDCAT-TABNAME = 'IT_EKKO'.
*I_FIELDCAT-REF_FIELDNAME = 'BSART'.
*I_FIELDCAT-REF_TABNAME = 'EKKO'.
*I_FIELDCAT-KEY = ''.
*I_FIELDCAT-EMPHASIZE = 'C510'.
**I_FIELDCAT-LOWERCASE = 'X'.
**I_FIELDCAT-SELTEXT_M = 'DOCUMENT TYPE'.
*I_FIELDCAT-OUTPUTLEN = 10.
*I_FIELDCAT-HOTSPOT = 'X'.
*I_FIELDCAT-DO_SUM = SPACE.
*APPEND I_FIELDCAT TO I_FIELDCAT.
*CLEAR I_FIELDCAT.
*
*
*
*POPULATING FIELD CATALOG BY USING FUNCTION MODULE
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
I_PROGRAM_NAME = SY-CPROG
I_INTERNAL_TABNAME = 'IT_EKKO'
I_INCLNAME = SY-CPROG
CHANGING
ct_fieldcat = I_FIELDCAT[].
*DISPLAYING REPORT AS ALV LIST
*CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
* EXPORTING
* I_CALLBACK_PROGRAM = SY-CPROG
* IT_FIELDCAT = I_FIELDCAT[]
* TABLES
* t_outtab = IT_EKKO.
**
*DISPLAYING REPORT AS ALV GRID
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = SY-CPROG
IT_FIELDCAT = I_FIELDCAT[]
TABLES
t_outtab = IT_EKKO.
Wednesday, October 1, 2008
Subscribe to:
Post Comments (Atom)
Archives
-
▼
2008
(167)
-
▼
October
(145)
- SAP ALE ABAP DETIAL
- SAP ABAP ALE IDOC'S
- SAP - DIFFERENCE BETWEEN CONVERSION AND INTERFACE
- BAPI AND IDOC ALE
- SAP ABAP MESSAGE CONTORL
- SAP IDOC'S IN ABAP INTRODUCTION
- SAP ABAP IDOC'S OUTLOOK
- SAP ABAP IDOC PROCESSING
- SAP ABAP IDOC'S BASIC TOOLS I
- SAP ABAP IDOC'S BASIC TOOLS II
- SAP ABAP IDOC'S INBOUND BASIC TOOLS III
- SAP IDOC OUT BOUND TRIGGERS II
- SAP IDOCS OUTBOUND TRIGGER II
- SAP IDOC'S OUTBOUND TRIGGER III
- SAP Work flow based outbound Idoc's
- SAP ALE Change Pointers
- SAP Dispatching ALE IDocs for Change Pointers
- SAP IDOC design and Processing
- SAP Creation of the IDoc Data
- SAP Developing an Outbound IDoc Function
- SAP Converting Data into IDoc Segment Format
- SAP Partner Profiles and Ports
- SAP Defining the partner profile for ALE IDOC
- SAP Data Ports ( WE21 ) in idoc
- SAP RFC in R/3
- SAP Workflow from Change Documents
- SAP ALE Distribution Scenario
- SAP Useful ALE Transaction Codes
- BAPI Creating IDocs and ALE Interface
- R/3 RFC from MS Office Via Visual Basic
- SD WORK FLOW SCENARIOS I
- SD WORK FLOW SCENARIOS II
- SD WORK FLOW SCENARIOS III
- SD WORK FLOW SCENARIOS IV
- SD WORK FLOW SCENARIOS V
- SD WORK FLOW SCENARIOS VI
- SD WORK FLOW SCENARIOS VII
- MM WORK FLOW SCENORIOS I
- MM WORK FLOW SCENORIOS II
- MM WORK FLOW SCENORIOS III
- MM WORK FLOW SCENORIOS IV
- MM WORK FLOW SCENORIOS V
- MM WORK FLOW SCENORIOS VI
- MM WORK FLOW SCENARIOS VII
- MM WORK FLOW SCENARIOS VIII
- MM WORK FLOW SCENARIOS IX
- MM WORK FLOW SCENARIOS X
- MM WORK FLOW SCENARIOS XI
- WORK FLOW SCENARIOS in SAP ABAP
- SAP ABAP WORK FLOW I
- SAP ABAP WORK FLOW II
- SAP ABAP WORK FLOW III
- SAP ABAP Work Flow IV
- SAP ABAP Workflow Technology
- SAP OPTIMIZATION
- abap type key ward
- PERFORMENCE TIPS
- SAP ABAP INTERNAL TABLES IN BRIEF
- SAP ABAP RUN TIME ANALASIS
- MEMORY In SAP ABAP
- NAVIGATION In SAP ABAP
- WORK BENCH AND TOOLS In SAP ABAP
- DATA OBJECTS AND STATEMENTS In SAP ABAP
- INTERNAL PROGRAM MODULARIZATION In SAP ABAP
- SAP ABAP CONSITENCEY THROUGH INPUT CHECKS
- RUN TIME ENVIRONMENT In SAP ABAP
- SAP ABAP INTER TABLE OPERATIONS
- STATEMENTS In SAP ABAP
- SAP ABAP INTERNAL TABLES
- SAP ABAP SUB ROUTIENS
- SAP ABAP FUNCTION MODULES AND GROUPS
- SAP ABAP QUARY ADMINSTRATION
- SAP ABAP SAVING LISTS AND BACK GROUND PROCESSING
- SAP ABAP PROGRAM INTERFACE
- SAP ABAP LOCK CONCEPT
- SAP ABAP AUTHORISATION CHECKS
- SAP ABAP PERFORMENCE TIPS
- In SAP SYSTEM FIELDS
- SAP ABAP CONTROL BLOCKS
- SAP ABAP BUFFERING
- SAP ABAP MATCH CODE OBJECTS
- SAP ABAP LOCKS
- SAP SAMPLE CODE FOR OUTPUT TO EXCEL AND IN PUT FIL...
- SAP MULTIPLE INTERACTIVE REPORT SAMPLE CODE
- MULTIPLE INTERACTIVE REPORT SAMPLE CODE II
- CALLING PROGRAM AND PASSING DATA
- SAP TECHNIQUES FOR LIST CREATION AND SAP QUARY
- SAP SELECTION SCREENS ABAP REPORT
- SAP ABAP FAQ ON SCRIPTS I
- SAP ABAP FAQ ON SCRIPTS II
- SAP ABAP FAQ ON SCRIPTS III
- IN SAP ABAP TABLE TYPES
- SAP ABAP TYPES OF VIEWS
- SAP ABAP DATA BASE UPDATES COMPLETE
- SAP ABAP LOCK CONCEPT
- SAP ORGANIZING DATABASE UPDATES
- SAP ENHANCEMENTS TO DICTIONERY ELEMENTS
- DATA BASE DIALOG IN ABAP
- ABAP DICTIONARY I
- PERFORMANCE DURING TABLE ACCESS
-
▼
October
(145)
No comments:
Post a Comment