REPORT ZALV .
type-pools : slis.
tables : spfli,SFLIGHT.
data : begin of itab occurs 0,
carrid like spfli-carrid,
connid like spfli-connid,
end of itab.
CONSTANTS:
GC_FORMNAME_TOP_OF_PAGE TYPE SLIS_FORMNAME VALUE 'TOP_OF_PAGE'.
data : g_fieldcat type slis_t_fieldcat_alv,
GS_LAYOUT TYPE SLIS_LAYOUT_ALV,
g_repid like sy-repid,
GT_EVENTS TYPE SLIS_T_EVENT,
g_layout type slis_layout_alv,
GS_KEYINFO TYPE SLIS_KEYINFO_ALV,
G_TABNAME_HEADER TYPE SLIS_TABNAME,
G_TABNAME_ITEM TYPE SLIS_TABNAME.
data : itab1 like sflight occurs 0 with header line.
g_repid = sy-repid.
select carrid connid into corresponding fields of table itab from
spfli.
G_TABNAME_HEADER = 'ITAB'.
G_TABNAME_ITEM = 'ITAB1'.
CLEAR GS_KEYINFO.
GS_KEYINFO-HEADER01 = 'CARRID'.
GS_KEYINFO-ITEM01 = 'CARRID'.
LOOP AT ITAB.
SELECT * FROM SFLIGHT WHERE CARRID = ITAB-CARRID.
MOVE-CORRESPONDING SFLIGHT TO ITAB1.
APPEND ITAB1.
CLEAR ITAB1.
ENDSELECT.
IF SY-SUBRC EQ 0.
EXIT.
ENDIF.
ENDLOOP.
PERFORM E03_EVENTTAB_BUILD USING GT_EVENTS[].
perform pc_fld using :
1 1 'CARRID' 'CARRIER' 10 ' H' 'ITAB',
1 2 'CONNID' 'CONNECTIONID' 04 ' H' 'ITAB',
2 1 'FLDATE' 'FLIGHT DET' 10 ' H' 'ITAB1',
2 2 'PRICE' 'PRICING DET' 20 ' H' 'ITAB1'.
GS_LAYOUT-F2CODE = '&ETA'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
* I_INTERFACE_CHECK = ' '
I_CALLBACK_PROGRAM = g_repid
* I_CALLBACK_PF_STATUS_SET = ' '
i_callback_user_command = 'ABCDEF'
IS_LAYOUT = GS_LAYOUT
IT_FIELDCAT = G_FIELDCAT
* IT_EXCLUDING =
* IT_SPECIAL_GROUPS =
* IT_SORT =
* IT_FILTER =
* IS_SEL_HIDE =
* I_SCREEN_START_COLUMN = 0
* I_SCREEN_START_LINE = 0
* I_SCREEN_END_COLUMN = 0
* I_SCREEN_END_LINE = 0
* I_DEFAULT = 'X'
* I_SAVE = ' '
* IS_VARIANT =
IT_EVENTS = GT_EVENTS[]
* IT_EVENT_EXIT =
*I_TABNAME_HEADER = G_TABNAME_HEADER
*I_TABNAME_ITEM = G_TABNAME_ITEM
* I_STRUCTURE_NAME_HEADER =
* I_STRUCTURE_NAME_ITEM =
*IS_KEYINFO = GS_KEYINFO
* IS_PRINT =
* IS_REPREP_ID =
* I_BUFFER_ACTIVE =
* I_BYPASSING_BUFFER =
* IMPORTING
* E_EXIT_CAUSED_BY_CALLER =
* ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = ITAB
*T_OUTTAB_ITEM = ITAB1
* EXCEPTIONS
* PROGRAM_ERROR = 1
* OTHERS = 2
.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* -----------------------------------------------------------*
form ABCDEF using r_ucomm like sy-ucomm rs_selfield type
slis_selfield.
* -----------------------------------------------------------*
case r_ucomm.
when '&IC1'.
read table itab index rs_selfield-tabindex.
if sy-subrc eq 0.
write : / 'sdfdsf'.
endif.
CLEAR r_ucomm.
endcase.
endform.
*&---------------------------------------------------------------------*
*& Form pc_fld
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
* -->P_1 text
* -->P_1 text
* -->P_0057 text
* -->P_0058 text
* -->P_10 text
* -->P_0060 text
* -->P_0061 text
*----------------------------------------------------------------------*
FORM pc_fld USING L P F D O R T.
DATA : T_FLD TYPE SLIS_FIELDCAT_ALV.
CLEAR T_FLD.
MOVE : L TO T_FLD-ROW_POS.
MOVE : P TO T_FLD-COL_POS.
MOVE : F TO T_FLD-FIELDNAME.
MOVE D TO : T_FLD-SELTEXT_L,
T_FLD-SELTEXT_M,
T_FLD-SELTEXT_S.
MOVE 'L' TO T_FLD-DDICTXT.
MOVE O TO T_FLD-OUTPUTLEN.
MOVE T TO T_FLD-TABNAME.
MOVE ' ' TO T_FLD-DO_SUM.
APPEND T_FLD TO G_FIELDCAT.
ENDFORM. " pc_fld
*---------------------------------------------------------------------*
* FORM E03_EVENTTAB_BUILD *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
* --> E03_LT_EVENTS *
*---------------------------------------------------------------------*
FORM E03_EVENTTAB_BUILD USING E03_LT_EVENTS TYPE SLIS_T_EVENT.
DATA: LS_EVENT TYPE SLIS_ALV_EVENT.
*
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = E03_LT_EVENTS.
READ TABLE E03_LT_EVENTS WITH KEY NAME = SLIS_EV_TOP_OF_PAGE
INTO LS_EVENT.
IF SY-SUBRC = 0.
MOVE GC_FORMNAME_TOP_OF_PAGE TO LS_EVENT-FORM.
APPEND LS_EVENT TO E03_LT_EVENTS.
ENDIF.
ENDFORM.
Friday, November 23, 2007
using alv grid real time implementation
Subscribe to:
Post Comments (Atom)
Blog Archive
-
▼
2007
(952)
-
▼
November
(716)
- SAP Paper Documents
- SAP Repository
- SAP R/3 Implementation and Maintenance Tips
- ABAP/4 programming language overview
- The interactive eLearning system for ABAP™
- Helpful System Administration ABAPS
- free download abap programmin pdf book
- examples of real time objects in sap abap(1)
- examples of real time objects in sap abap
- work flow example2
- Workflow tips
- Miscellaneous sap abap faq
- BDC , LSMW, Conversions faq in abap
- Sap Scripts & Smart forms faqs in abap
- performance tuning in abap faqs
- Real Time BDC & LSMW faqs
- Real Time ABAP Internal Tables faqs
- Real Time ABAP Reports faqs
- Real Time questions ..in sap ABAP
- SAP ABAP FAQ (Technical)
- ABAP and Unicode
- ABAP and JavaScript
- ABAP Objects
- ABAP Database Access
- Running ABAP Programs
- ABAP User Dialogs
- The ABAP Programming Language
- Creating and Changing ABAP Programs
- Overview of the Components of Application Programs
- Introduction to ABAP
- ABAP Programming Documentation
- FREE DOWNLOAD ALE, EDI & IDOCS
- Conversion of IDOCs to XML.pdf
- FREE DOWNLOAD IDOC Interface Technology
- FREE DOWNLOAD EDI, IDOC Interface
- FREE DOWNLOAD IDOC BOOK
- FREE DOWNLOAD LSMW - Idoc Inbound Processing
- FREE DOWNLOAD SAP ABAP Idoc Interface
- FREE DOWNLOAD Java for SAP
- FREE DOWNLOAD Java for ABAP Programmers
- FREE DOWNLOAD Java and BAPI technology for EP
- free download Building Web Services with Java and ...
- free download Enable SAP with the power of Javascript
- FREE DOWNLOAD ABAP Training Simulator
- FREE DOWNLOAD SAP Accounting Training Simulators
- free download SAPScripts Made Easy
- CONDENSE
- CONSTANTS
- ABAP Quick Viewer
- sap abap XXL (EXtended Export of Lists)
- Some ABAP/4 Query header line variable
- Understanding SAP Query
- ABAP/4 Query
- ABAP/4 Query Hints and Tips
- SAP Website Links Exchange for ABAP, Basis or Cons...
- sap abap Program for Generate IDoc
- sap abap program for Reads an existing Idoc and di...
- List of ABAP Function modules
- sap abap FTP programming
- sap abap program for Issuing an Unix Command from ...
- sap abap program for RFC call to get Server List
- sap abap program for A SAP Pop-out Calculator
- sap ABAP program for Timers and Auto-refresh
- sap abap program for WS_EXECUTE to called External...
- sap abap programming Execute DOS Command from ABAP...
- To execute a dos command from ABAP
- sap abap program for Make your SAPGUI Disappear an...
- sap abap program for Using Function Modules F4_FIL...
- abp program for How to Restrict the Select Options
- sap abap program for Take Values from Selection-Sc...
- sap abap program for Change Text Into Password
- sap abap program for Function Module for Encryptio...
- sap abap program for FM VRM_SET_VALUE To List Box
- sap abap program for Value Request For Parameter
- sap abap program for Pop a Message to specific SAP...
- ABAP Pop-out box for user confirmation
- sap ABAP program for POP-UP Window
- sap abap program Sample XML Source Code For SAP
- sap abap XML file to word document through SAP
- sap abap program for How to Write Web Reports in SAP
- sap abap conversion Program to Test Line Selection...
- sap abap program for String Handling in ABAP - Rem...
- sap abap program for Split String into two parts a...
- sap abap conversion Program For Printing Prime Number
- sap abap program for How can I get Ascii value of ...
- sap abap program for Figure to Words for India but...
- sap abap conversion program for Print Number Value...
- sap abap conversion program for Insert a special T...
- sap abap program for String Handling in ABAP - Rem...
- sap abap program for Split String into two parts a...
- sap abap conversion Program For Printing Prime Number
- sap abap program for How can I get Ascii value of ...
- sap abap program for Figure to Words for India but...
- sap abap conversion program for Print Number Value...
- sap abap conversion program for Insert a special T...
- sap abap program for Convert SAP Spool List to HTML
- sap program for Convert Month to Word in ABAP
- ABAP function to convert Number to Words
- sap abap program for How to Create Tree Control
- sap abap A sample Tree Programming
-
▼
November
(716)
No comments:
Post a Comment