Module pool programming with Abap Objects

Hi masters,
Somebody tell me that you can directly call a local class in a module pool.
    Is that possible?
    Can anybody refer me to any kind of information?
Thanks a lot.

Well, thanks for the answer, but not was the one i was waiting for... it wasn't helpful.
But, i've continued searching for answers... and i've found that:
OO Transactions Locate the document in its SAP Library structure
In transaction maintenance (SE93), you can specify a transaction code as an OO transaction.
You either link the transaction code to the Transaction Service of the Structure link ABAP Object Services for persistent objects or to a public method of a global or local class of a program. When calling up a transaction that is linked to an instance method, the system automatically generates an instance of the class in its own internal session.
An example of a link between a transaction code and an instance method of a local class of an unspecified ABAP program:
Example
*& Modulpool DEMO_OO_TRANSACTION *
program DEMO_OO_TRANSACTION.
class DEMO_CLASS definition.
public section.
methods INSTANCE_METHOD.
endclass.
class DEMO_CLASS implementation.
method INSTANCE_METHOD.
message 'Instance method in local class' type 'I'.
endmethod.
endclass.
The DEMO_OO_TRANSACTION program is a module pool of type M that does not contain any screens or dialog modules. Instead, the program contains the definition of a local class DEMO_CLASS.
The DEMO_OO_METHOD transaction code is linked to this program as follows:
The start object of the transaction is Method of a class (OO transaction).
OO transaction model is not selected.
The Class Name is DEMO_CLASS.
The Method is INSTANCE_METHOD.
Local in program is selected and DEMO_OO_TRANSACTION specified.
When the transaction is called up, the program is loaded, an instance of the class is created, and the method is executed.
Leaving content frame
That's what i wanted.
I hope it would be helpful for anyone else.

Similar Messages

  • Links/Docs for Module Pool Programing using abap objects

    Hi all,
    Can anyone send me links/docs related to Module Pool programing using Abap Objects.
    Thanks n Regards
    Maruthi Rao. A

    hi maruthi rao,
    check the below link
    http://abapcode.blogspot.com/2007/06/object-oriented-alv-sample-program-to.html

  • Module Pool Programming using Abap Objects

    Hi gurus.,
    I need to create a module pool program with tabstrips and tablecontrols using Abap objects...plz guide me how i can achieve this... i am very much confused.. i dont know how and where to start .. plz send me documents and sample codes related to this topic..Also hoe i can implement f4 help in screen fields.. plz help me with Sample Code....
    Regards.,
    S.Sivakumar

    Hi Marcelo Ramos.,
         here is my code without using WebLOg ..
    PROGRAM  ZACR018_BOXKOD                          .
           TABLES DECLARATION
    TABLES: ZACT02_BOXKOD, ZACS018_STR, MARA.
    CONTROLS TABC TYPE TABLEVIEW USING SCREEN 102.
           END OF TABLES DECLARATION
    DEFINE DYN_DECLARE_CREATE.
    DATA: &1 TYPE REF TO &2.
    CREATE OBJECT &1.
    END-OF-DEFINITION.
    CONSTANTS C_WERKS TYPE WERKS_D VALUE '7600'.
    CONSTANTS C_REPID TYPE SY-REPID VALUE SY-REPID.
    CONSTANTS C_VERID TYPE VERID VALUE '0001'.
    CONSTANTS C_MDV01 TYPE MDV01 VALUE 'F3LB02'.
    CLASS CL_TABLE_CONTROL DEFINITION.
    PUBLIC SECTION.
    CLASS-DATA: IT_C_DISPLAY TYPE STANDARD TABLE OF ZACS018_STR.
    CLASS-DATA: WA_DISPLAY TYPE ZACS018_STR.
    CLASS-DATA: WA_COLS LIKE LINE OF TABC-COLS.
    CLASS-METHODS M1 IMPORTING WA_C_DISPLAY TYPE ZACS018_STR EXPORTING ZACS018_STR_C TYPE ZACS018_STR.
    CLASS-METHODS M2 IMPORTING ZACS018_STR_C TYPE ZACS018_STR CHANGING  IT_C_DISPLAY LIKE IT_C_DISPLAY.
    CLASS-METHODS M3 IMPORTING SAVE_OK TYPE SY-UCOMM CHANGING C_TABC TYPE CX_TABLEVIEW.
    CLASS-METHODS M4 IMPORTING MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN
                               PATTERNSLNO    TYPE ZACT02_BOXKOD-PATTERNSLNO
                               SAVE_OK TYPE SY-UCOMM
                               CHANGING C_TABC TYPE CX_TABLEVIEW.
    ENDCLASS.
    CLASS CL_TABLE_CONTROL IMPLEMENTATION.
    METHOD M1.
    ZACS018_STR_C = WA_C_DISPLAY.
    ENDMETHOD.
    METHOD M2.
    DESCRIBE TABLE IT_C_DISPLAY.
    IF TABC-CURRENT_LINE > SY-TFILL.
        APPEND ZACS018_STR_C TO IT_C_DISPLAY.
    ELSE.
        MODIFY IT_C_DISPLAY FROM ZACS018_STR_C INDEX TABC-CURRENT_LINE.
    ENDIF.
    ENDMETHOD.
    METHOD M3.
    IF SAVE_OK = 'CHECK'.
    LOOP AT C_TABC-COLS INTO WA_COLS.
    IF WA_COLS-SCREEN-GROUP2 = 'BOT'.
    WA_COLS-SCREEN-INPUT = 0.
    MODIFY C_TABC-COLS FROM WA_COLS INDEX SY-TABIX.
    ENDIF.
    ENDLOOP.
    ELSE.
    LOOP AT C_TABC-COLS INTO WA_COLS.
    IF WA_COLS-SCREEN-GROUP2 = 'BOT'.
    WA_COLS-SCREEN-INPUT = 1.
    MODIFY C_TABC-COLS FROM WA_COLS INDEX SY-TABIX.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDMETHOD.
    METHOD M4.
    IF MASTER_PATTERN IS INITIAL OR PATTERNSLNO  IS INITIAL.
    LOOP AT C_TABC-COLS INTO WA_COLS.
    IF WA_COLS-SCREEN-GROUP2 = 'BOT'.
    WA_COLS-SCREEN-INPUT = 0.
    MODIFY C_TABC-COLS FROM WA_COLS INDEX SY-TABIX.
    ENDIF.
    ENDLOOP.
    ELSE.
    IF SAVE_OK NE 'CHECK'.
    LOOP AT C_TABC-COLS INTO WA_COLS.
    IF WA_COLS-SCREEN-GROUP2 = 'BOT'.
    WA_COLS-SCREEN-INPUT = 1.
    MODIFY C_TABC-COLS FROM WA_COLS INDEX SY-TABIX.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    ENDCLASS.
    INTERFACE I_DATA.
    DATA: WA_MARA TYPE MARA.
    DATA: WA_MARC TYPE MARC.
    DATA: WA_MAST TYPE MAST.
    DATA: WA_STKO TYPE STKO.
    DATA: WA_MKAL TYPE MKAL.
    DATA: IT_STPOX TYPE STANDARD TABLE OF STPOX.
    DATA: WA_STPOX TYPE STPOX.
    DATA: WA_ZACT02_BOXKOD TYPE ZACT02_BOXKOD.
    DATA: IT_C_DISPLAY TYPE STANDARD TABLE OF ZACS018_STR.
    DATA: IT_SORT_DISPLAY TYPE STANDARD TABLE OF ZACS018_STR.
    DATA: WA_DISPLAY TYPE ZACS018_STR.
    DATA: W_YIELD(5)  TYPE P DECIMALS 2.
    METHODS PARTNO_VAL IMPORTING PARTCODE TYPE ZACS018_STR-PARTCODE.
    METHODS MAINBI_VAL IMPORTING MAINB    TYPE ZACS018_STR-MAINB.
    METHODS CAVITY_VAL IMPORTING CAVITY   TYPE ZACS018_STR-CAVITY.
    METHODS GET_COMP_WT IMPORTING PARTCODE TYPE ZACS018_STR-PARTCODE EXPORTING GROSSWT TYPE ZACS018_STR-GROSSWT.
    METHODS NETWT_VAL IMPORTING NETWT TYPE ZACS018_STR-NETWT GROSSWT TYPE ZACS018_STR-GROSSWT.
    METHODS MASPAT_VAL IMPORTING MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN.
    METHODS PATSLNO_VAL IMPORTING PATTERNSLNO TYPE ZACT02_BOXKOD-PATTERNSLNO
                                  MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN .
    METHODS MAX_REF EXPORTING VERSNO TYPE ZACT02_BOXKOD-VERSNO.
    METHODS NOOFBOX_VAL IMPORTING BMSCH TYPE ZACT02_BOXKOD-BMSCH.
    METHODS TOTTIME_VAL IMPORTING VGW01 TYPE ZACT02_BOXKOD-VGW01.
    METHODS TOTRUNWT IMPORTING IT_C_DISPLAY LIKE IT_C_DISPLAY
                     EXPORTING W_SUM_RUNWT LIKE ZACS018_STR-NETWT.
    METHODS TOTCOMP_WT  IMPORTING IT_C_DISPLAY LIKE IT_C_DISPLAY
                        EXPORTING W_SUM_COMPWT LIKE ZACS018_STR-NETWT.
    METHODS CHECK_OK IMPORTING SAVE_OK TYPE SY-UCOMM.
    METHODS SCREEN_DISPLAY IMPORTING MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN
                                     PATTERNSLNO    TYPE ZACT02_BOXKOD-PATTERNSLNO
                                     SAVE_OK TYPE SY-UCOMM.
    METHODS DUP_CHECK IMPORTING IT_C_DISPLAY LIKE IT_C_DISPLAY.
    METHODS BOX_YLD IMPORTING W_SUM_COMPWT LIKE ZACS018_STR-NETWT
                              W_TOT_WT LIKE ZACS018_STR-NETWT
                    EXPORTING W_YIELD LIKE W_YIELD.
    ENDINTERFACE.
    CLASS CL_CONTROL_EVENTS DEFINITION.
    PUBLIC SECTION.
    CLASS-DATA: C_WERKS TYPE WERKS_D VALUE C_WERKS.
    INTERFACES I_DATA.
    ENDCLASS.
    CLASS CL_CONTROL_EVENTS IMPLEMENTATION.
    METHOD I_DATA~PARTNO_VAL.
    SELECT SINGLE * FROM MARA INTO I_DATA~WA_MARA WHERE MATNR = PARTCODE.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-001 TYPE 'E'.
    ELSE.
    IF I_DATA~WA_MARA-MTART NE 'HALB'.
    MESSAGE TEXT-002 TYPE 'E'.
    ENDIF.
    SELECT SINGLE * FROM MARC INTO I_DATA~WA_MARC WHERE MATNR = PARTCODE AND
                                                 WERKS = C_WERKS.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-003 TYPE 'E'.
    ELSE.
    IF I_DATA~WA_MARC-FEVOR NE 'KOD'.
    MESSAGE TEXT-004 TYPE 'E'.
    ENDIF.
    ENDIF.
    ENDIF.
    SELECT SINGLE * FROM MKAL INTO I_DATA~WA_MKAL WHERE MATNR = PARTCODE AND
                                           WERKS = C_WERKS  AND
                                           VERID = C_VERID  AND
                                           MDV01 = C_MDV01.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-028 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~CAVITY_VAL.
    SET CURSOR FIELD 'ZACS018_STR-CAVITY' LINE SY-STEPL.
    IF CAVITY IS INITIAL.
    MESSAGE TEXT-005 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~MAINBI_VAL.
    SET CURSOR FIELD 'ZACS018_STR-MAINB' LINE SY-STEPL.
    IF MAINB IS INITIAL.
    MESSAGE TEXT-006 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~GET_COMP_WT.
    SET CURSOR FIELD 'ZACS018_STR-PARTCODE' LINE SY-STEPL.
    *SELECT SINGLE MAST~MATNR
                MAST~WERKS
                MAST~STLAL
                STKO~DATUV
                INTO (I_DATAWA_MAST-MATNR,I_DATAWA_MAST-WERKS,I_DATAWA_MAST-STLAL,I_DATAWA_STKO-DATUV)
                FROM MAST AS MAST INNER JOIN STKO AS STKO
                ON STKOSTLNR = MASTSTLNR AND STKOSTLAL = MASTSTLAL
                WHERE  MAST~MATNR = PARTCODE AND
                       STKO~STLST = '1' AND
                       STKO~STLTY = 'M' AND
                       STKO~LKENZ  = '' AND
                       STKO~LOEKZ  = ''.
    SELECT SINGLE * FROM MAST INTO I_DATA~WA_MAST WHERE MATNR = PARTCODE AND
                                                        STLAN = '1' AND
                                                        STLAL = '01' AND
                                                        WERKS = C_WERKS.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-009 TYPE 'E'.
    ENDIF.
    *CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
    EXPORTING
      PERCENTAGE       = 50
      TEXT             = TEXT-007.
    *WAIT UP TO 2 SECONDS.
    REFRESH I_DATA~IT_STPOX.
    CALL FUNCTION 'CS_BOM_EXPL_MAT_V2'
    EXPORTING
      FTREL                       = 'X'
      ALEKZ                       = ' '
      ALTVO                       = ' '
      AUFSW                       = ' '
      AUMGB                       = ' '
      AUMNG                       = 0
      AUSKZ                       = 'X'
      AMIND                       = ' '
      BAGRP                       = ' '
      BEIKZ                       = ' '
      BESSL                       = ' '
      BGIXO                       = 'X'
      BREMS                       = 'X'
       CAPID                       = 'PP01'
      CHLST                       = ' '
      COSPR                       = ' '
      CUOBJ                       = 000000000000000
      CUOVS                       = 0
      CUOLS                       = ' '
       DATUV                       = SY-DATUM
      DELNL                       = SPACE
      DRLDT                       = ' '
      EHNDL                       = '1'
      EMENG                       = 0
      ERSKZ                       = ' '
      ERSSL                       = ' '
      FBSTP                       = ' '
      KNFBA                       = ' '
      KSBVO                       = ' '
      MBWLS                       = ' '
      MKTLS                       = 'X'
      MDMPS                       = ' '
       MEHRS                       = ' '
      MKMAT                       = ' '
      MMAPS                       = ' '
      SALWW                       = ' '
      SPLWW                       = ' '
       MMORY                       = '0'
       MTNRV                       = PARTCODE
      NLINK                       = ' '
      POSTP                       = ' '
      RNDKZ                       = ' '
      RVREL                       = ' '
      SANFR                       = ' '
      SANIN                       = ' '
      SANKA                       = ' '
      SANKO                       = ' '
      SANVS                       = ' '
      SCHGT                       = ' '
      STKKZ                       = ' '
       STLAL                       = '01'
       STLAN                       = '1'
      STPST                       = 0
      SVWVO                       = 'X'
       WERKS                       = C_WERKS
      NORVL                       = ' '
      MDNOT                       = ' '
      PANOT                       = ' '
      QVERW                       = ' '
      VERID                       = ' '
      VRSVO                       = 'X'
    IMPORTING
      TOPMAT                      =
      DSTST                       =
      TABLES
        STB                         = I_DATA~IT_STPOX
      MATCAT                      =
    EXCEPTIONS
       ALT_NOT_FOUND               = 1
       CALL_INVALID                = 2
       MATERIAL_NOT_FOUND          = 3
       MISSING_AUTHORIZATION       = 4
       NO_BOM_FOUND                = 5
       NO_PLANT_DATA               = 6
       NO_SUITABLE_BOM_FOUND       = 7
       CONVERSION_ERROR            = 8
       OTHERS                      = 9
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    LOOP AT I_DATA~IT_STPOX INTO I_DATA~WA_STPOX.
    SELECT SINGLE FEVOR FROM MARC INTO I_DATA~WA_MARC-FEVOR WHERE MATNR = I_DATA~WA_STPOX-IDNRK AND
                                                           WERKS = I_DATA~WA_STPOX-WERKS AND
                                                           FEVOR = 'MLT'.
    IF SY-SUBRC EQ 0.
    GROSSWT = I_DATA~WA_STPOX-MNGLG.
    EXIT.
    ELSE.
    CLEAR GROSSWT.
    ENDIF.
    ENDLOOP.
    IF GROSSWT IS INITIAL.
    MESSAGE TEXT-008 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~NETWT_VAL.
    SET CURSOR FIELD 'ZACS018_STR-NETWT' LINE SY-STEPL.
    IF NETWT IS INITIAL.
    MESSAGE TEXT-010 TYPE 'E'.
    ELSE.
    IF NETWT >= GROSSWT.
    MESSAGE TEXT-011 TYPE 'E'.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~MASPAT_VAL.
    IF MASTER_PATTERN IS INITIAL.
    MESSAGE TEXT-014 TYPE 'E'.
    ENDIF.
    SELECT SINGLE * FROM MARA INTO I_DATA~WA_MARA WHERE MATNR = MASTER_PATTERN.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-001 TYPE 'E'.
    ELSE.
    IF I_DATA~WA_MARA-MTART NE 'FHMI'.
    MESSAGE TEXT-012 TYPE 'E'.
    ENDIF.
    SELECT SINGLE * FROM MARC INTO I_DATA~WA_MARC WHERE MATNR = MASTER_PATTERN AND
                                                 WERKS = C_WERKS.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-003 TYPE 'E'.
    ELSE.
    IF I_DATA~WA_MARC-FEVOR NE 'MLD'.
    MESSAGE TEXT-013 TYPE 'E'.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~PATSLNO_VAL.
    IF PATTERNSLNO IS INITIAL.
    MESSAGE TEXT-016 TYPE 'E'.
    ENDIF.
    SELECT SINGLE * FROM ZACT02_BOXKOD INTO I_DATA~WA_ZACT02_BOXKOD WHERE MASTER_PATTERN = MASTER_PATTERN
                                                               AND PATTERNSLNO    = PATTERNSLNO.
    IF SY-SUBRC EQ 0.
    MESSAGE TEXT-015 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~MAX_REF.
    SELECT SINGLE MAX( VERSNO ) FROM ZACT02_BOXKOD INTO VERSNO.
    VERSNO = VERSNO + 1.
    ENDMETHOD.
    METHOD I_DATA~NOOFBOX_VAL.
    IF BMSCH IS INITIAL.
    LOOP AT SCREEN.
    IF SCREEN-GROUP2 = 'BOT' AND SCREEN-NAME <> 'ZACT02_BOXKOD-PRD_ACT' AND SCREEN-NAME <> 'ZACT02_BOXKOD-SHOTS'.
    SCREEN-INPUT = 1.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    MESSAGE TEXT-017 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~TOTTIME_VAL.
    IF VGW01 IS INITIAL.
    MESSAGE TEXT-018 TYPE 'E'.
    ENDIF.
    IF VGW01 > 480.
    MESSAGE TEXT-019 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~TOTRUNWT.
    CLEAR W_SUM_RUNWT.
    LOOP AT IT_C_DISPLAY INTO I_DATA~WA_DISPLAY.
    W_SUM_RUNWT = W_SUM_RUNWT + I_DATA~WA_DISPLAY-NETWT * I_DATA~WA_DISPLAY-CAVITY.
    ENDLOOP.
    ENDMETHOD.
    METHOD I_DATA~TOTCOMP_WT.
    CLEAR W_SUM_COMPWT.
    LOOP AT IT_C_DISPLAY INTO I_DATA~WA_DISPLAY.
    W_SUM_COMPWT = W_SUM_COMPWT + I_DATA~WA_DISPLAY-GROSSWT * I_DATA~WA_DISPLAY-CAVITY.
    ENDLOOP.
    ENDMETHOD.
    METHOD I_DATA~CHECK_OK.
    IF SAVE_OK = 'CHECK'.
    LOOP AT SCREEN.
    IF SCREEN-GROUP2 = 'BOT'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ELSE.
    LOOP AT SCREEN.
    IF SCREEN-GROUP2 = 'BOT'.
    SCREEN-INPUT = 1.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~SCREEN_DISPLAY.
    IF MASTER_PATTERN IS INITIAL
    OR PATTERNSLNO IS INITIAL.
    LOOP AT SCREEN.
    IF SCREEN-GROUP2 = 'BOT'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ELSE.
    IF SAVE_OK NE 'CHECK'.
    LOOP AT SCREEN.
    IF SCREEN-GROUP2 = 'BOT'.
    SCREEN-INPUT = 1.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    METHOD I_DATA~DUP_CHECK. " IMPORTING IT_C_DISPLAY
    DATA: W_PARTCODE LIKE I_DATA~WA_DISPLAY-PARTCODE.
    I_DATA~IT_SORT_DISPLAY = IT_C_DISPLAY.
    SORT I_DATA~IT_SORT_DISPLAY BY PARTCODE.
    CLEAR W_PARTCODE.
    LOOP AT I_DATA~IT_SORT_DISPLAY INTO I_DATA~WA_DISPLAY.
    IF W_PARTCODE = I_DATA~WA_DISPLAY-PARTCODE.
    MESSAGE TEXT-027 TYPE 'E'.
    ENDIF.
    W_PARTCODE = I_DATA~WA_DISPLAY-PARTCODE.
    ENDLOOP.
    ENDMETHOD.
    METHOD I_DATA~BOX_YLD.
    W_YIELD = ( W_SUM_COMPWT / W_TOT_WT ) * 100.
    ENDMETHOD.
    ENDCLASS.
    inherited class for edit mode
    CLASS CL_CONTROL_EDIT DEFINITION INHERITING FROM CL_CONTROL_EVENTS .
    PUBLIC SECTION.
    METHODS GET_DATA IMPORTING MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN
                                  PATTERNSLNO TYPE ZACT02_BOXKOD-PATTERNSLNO
                     EXPORTING        VERSNO  TYPE ZACT02_BOXKOD-VERSNO
                                  CHANGING ZACT02_BOXKOD TYPE ZACT02_BOXKOD
                                           IT_C_DISPLAY  LIKE I_DATA~IT_C_DISPLAY
                                           IT_DEL_DISPLAY LIKE I_DATA~IT_C_DISPLAY
                                           TABC TYPE CX_TABLEVIEW.
    METHODS PATSLNO_VAL_CHG IMPORTING PATTERNSLNO TYPE ZACT02_BOXKOD-PATTERNSLNO
                                  MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN .
    ENDCLASS.
    CLASS CL_CONTROL_EDIT IMPLEMENTATION.
    METHOD GET_DATA.
    IF MASTER_PATTERN IS NOT INITIAL AND PATTERNSLNO IS NOT INITIAL.
    IF IT_C_DISPLAY IS INITIAL.
    IF IT_DEL_DISPLAY IS INITIAL.
    SELECT SINGLE MAX( VERSNO ) FROM ZACT02_BOXKOD INTO VERSNO WHERE
                                     MASTER_PATTERN = MASTER_PATTERN AND
                                     PATTERNSLNO    = PATTERNSLNO.
    SELECT SINGLE * FROM ZACT02_BOXKOD INTO ZACT02_BOXKOD WHERE
       MASTER_PATTERN = MASTER_PATTERN AND
       PATTERNSLNO    = PATTERNSLNO    AND
       VERSNO         = VERSNO..
    SELECT PARTCODE MAINB CAVITY GROSSWT NETWT FROM ZACT02_BOXKOD INTO
                    CORRESPONDING FIELDS OF TABLE IT_C_DISPLAY WHERE
                    MASTER_PATTERN = MASTER_PATTERN AND
                    PATTERNSLNO    = PATTERNSLNO    AND
                    VERSNO         = VERSNO.
    IT_DEL_DISPLAY[] = IT_C_DISPLAY[].
    DESCRIBE TABLE IT_C_DISPLAY.
    TABC-LINES = SY-TFILL.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    METHOD PATSLNO_VAL_CHG.
    SELECT SINGLE * FROM ZACT02_BOXKOD INTO I_DATA~WA_ZACT02_BOXKOD WHERE MASTER_PATTERN = MASTER_PATTERN
                                                               AND PATTERNSLNO    = PATTERNSLNO.
    IF PATTERNSLNO IS INITIAL.
    MESSAGE TEXT-016 TYPE 'E'.
    ENDIF.
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-022 TYPE 'E'.
    ENDIF.
    ENDMETHOD.
    ENDCLASS.
    inheriting for display
    CLASS CL_CONTROL_DISPLAY DEFINITION INHERITING FROM CL_CONTROL_EDIT .
    PUBLIC SECTION.
    METHODS GET_DISPLAY_DATA IMPORTING MASTER_PATTERN TYPE ZACT02_BOXKOD-MASTER_PATTERN
                                       PATTERNSLNO TYPE ZACT02_BOXKOD-PATTERNSLNO
                                       VERSNO TYPE ZACT02_BOXKOD-VERSNO
                              CHANGING IT_C_DISPLAY LIKE I_DATA~IT_C_DISPLAY
                                       ZACT02_BOXKOD TYPE ZACT02_BOXKOD
                                       TABC TYPE CX_TABLEVIEW.
    ENDCLASS.
    CLASS CL_CONTROL_DISPLAY IMPLEMENTATION.
    METHOD GET_DISPLAY_DATA.
    SELECT SINGLE * FROM ZACT02_BOXKOD INTO ZACT02_BOXKOD WHERE
       MASTER_PATTERN = MASTER_PATTERN AND
       PATTERNSLNO    = PATTERNSLNO    AND
       VERSNO         = VERSNO..
    IF SY-SUBRC <> 0.
    MESSAGE TEXT-026 TYPE 'E'.
    ENDIF.
    SELECT PARTCODE MAINB CAVITY GROSSWT NETWT FROM ZACT02_BOXKOD INTO
                    CORRESPONDING FIELDS OF TABLE IT_C_DISPLAY WHERE
                    MASTER_PATTERN = MASTER_PATTERN AND
                    PATTERNSLNO    = PATTERNSLNO    AND
                    VERSNO         = VERSNO.
    DESCRIBE TABLE IT_C_DISPLAY.
    TABC-LINES = SY-TFILL.
    ENDMETHOD.
    ENDCLASS.
    DATA: O_CONTROL_EVENTS TYPE REF TO CL_CONTROL_EVENTS.
    DATA: O_CONTROL_EVENTS_EDIT TYPE REF TO CL_CONTROL_EDIT.
    DATA: O_CONTROL_EVENTS_DISPLAY TYPE REF TO CL_CONTROL_DISPLAY.
           SELECTION SCREEN
           END OF SELECTION SCREEN
           VARIABLE DECLARATION         BEGIN WITH W_
    DATA: OK_CODE TYPE SY-UCOMM,
          SAVE_OK TYPE SY-UCOMM.
    DATA: W_TOT_WT LIKE ZACS018_STR-NETWT,
          W_SUM_COMPWT LIKE ZACS018_STR-NETWT,
          W_SUM_RUNWT LIKE ZACS018_STR-NETWT,
          W_YIELD(5)  TYPE P DECIMALS 2.
    DATA: W_TIMLO TYPE SY-TIMLO,
          W_MODE  TYPE SY-UCOMM.
    DATA: W_SCREEN_NO TYPE SY-DYNNR.
           END OF VARIABLE DECLARATION
           WORK AREAS DECLARATION         BEGIN WITH WA_
    DATA: WA_DISPLAY TYPE ZACS018_STR.
           END OF WORK AREAS DECLARATION
           INTERNAL TABLES          BEGIN WITH IT_
    DATA: IT_DISPLAY TYPE ZACS018_STR OCCURS 0.
    DATA: IT_DISPLAY_PRD TYPE ZACS018_STR OCCURS 0.
    DATA: IT_DEL_DISPLAY TYPE ZACS018_STR OCCURS 0.
    DATA: IT_ZACT02_BOXKOD TYPE ZACT02_BOXKOD OCCURS 0 WITH HEADER LINE.
    DATA: IT_ZACT02_BOXKOD_DEL TYPE ZACT02_BOXKOD OCCURS 0 WITH HEADER LINE.
    DATA: BEGIN OF IT_F4MASTERPAT OCCURS 0,
          MASTER_PATTERN LIKE ZACT02_BOXKOD-MASTER_PATTERN,
          END OF IT_F4MASTERPAT.
    DATA: BEGIN OF IT_F4PATSLNO OCCURS 0,
          MASTER_PATTERN LIKE ZACT02_BOXKOD-MASTER_PATTERN,
          PATTERNSLNO    LIKE ZACT02_BOXKOD-PATTERNSLNO,
          VERSNO         LIKE ZACT02_BOXKOD-VERSNO,
          END OF IT_F4PATSLNO.
    DATA: IT_EXCLUDE TYPE TABLE OF SY-UCOMM..
    DATA : IT_DYNPRO LIKE  DYNPREAD OCCURS 0 WITH HEADER LINE.
           END OF INTERNAL TABLES DECLARATIONS
    LOAD-OF-PROGRAM.
    CREATE OBJECT O_CONTROL_EVENTS.
    *&      Module  USER_COMMAND_0100  INPUT
          text
    MODULE USER_COMMAND_0100 INPUT.
    SAVE_OK = OK_CODE.
    CLEAR OK_CODE.
    W_MODE = SAVE_OK.
    CASE SAVE_OK.
    WHEN 'CREATE'.
    CALL SCREEN 101.
    WHEN 'CHANGE'.
    CREATE OBJECT O_CONTROL_EVENTS_EDIT.
    CALL SCREEN 101.
    WHEN 'DISPLAY'.
    APPEND 'SAVE'  TO IT_EXCLUDE.
    APPEND 'CHECK' TO IT_EXCLUDE.
    APPEND 'ADD'   TO IT_EXCLUDE.
    CREATE OBJECT O_CONTROL_EVENTS_DISPLAY.
    CALL SCREEN 101.
    ENDCASE.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    *&      Module  STATUS_0102  OUTPUT
          text
    MODULE STATUS_0102 OUTPUT.
    CALL METHOD CL_TABLE_CONTROL=>M3 EXPORTING SAVE_OK = SAVE_OK CHANGING C_TABC = TABC.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~CHECK_OK EXPORTING SAVE_OK = SAVE_OK.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~SCREEN_DISPLAY EXPORTING MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN
                                     PATTERNSLNO    = ZACT02_BOXKOD-PATTERNSLNO
                                     SAVE_OK = SAVE_OK.
    CALL METHOD CL_TABLE_CONTROL=>M4 EXPORTING MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN
                                               PATTERNSLNO    = ZACT02_BOXKOD-PATTERNSLNO
                                               SAVE_OK        = SAVE_OK
                                               CHANGING C_TABC = TABC.
    DESCRIBE TABLE IT_DISPLAY.
    IF TABC-LINES <= 1.
    IF SY-TFILL = 0.
    TABC-LINES = 1.
    ENDIF.
    ENDIF.
    IF SAVE_OK NE 'CHECK'.
    IF ZACT02_BOXKOD-TOOL_ACT <> 'X'.
    CLEAR ZACT02_BOXKOD-PRD_ACT.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ZACT02_BOXKOD-PRD_ACT'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ELSE.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ZACT02_BOXKOD-PRD_ACT'.
    SCREEN-INPUT = 1.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDIF.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~TOTRUNWT EXPORTING IT_C_DISPLAY = IT_DISPLAY
                                           IMPORTING W_SUM_RUNWT = W_SUM_RUNWT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~TOTCOMP_WT  EXPORTING IT_C_DISPLAY = IT_DISPLAY
                                           IMPORTING W_SUM_COMPWT = W_SUM_COMPWT.
    CLEAR W_TOT_WT.
    W_TOT_WT = W_SUM_RUNWT + W_SUM_COMPWT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~BOX_YLD EXPORTING W_SUM_COMPWT = W_SUM_COMPWT
                                               W_TOT_WT = W_TOT_WT
                                                 IMPORTING W_YIELD = W_YIELD.
    IF W_MODE <> 'CREATE'.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ZACT02_BOXKOD-SHOTS'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    IF W_MODE = 'DISPLAY'.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ADD' OR SCREEN-NAME = 'ICON_DELETE'.
    SCREEN-INPUT = '0'.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDMODULE.                 " STATUS_0102  OUTPUT
    *&      Module  STATUS_0101  OUTPUT
          text
    MODULE STATUS_0101 OUTPUT.
      SET PF-STATUS 'STANDARD' EXCLUDING 'SAVE'.
      IF W_MODE = 'CREATE'.
      SET TITLEBAR  'STANDARD'.
      ELSEIF W_MODE = 'DISPLAY'.
      SET TITLEBAR  'STD_DIS'.
      ELSE.
      SET TITLEBAR 'STD_EDIT'.
      ENDIF.
      IF SAVE_OK = 'CHECK'.
      DESCRIBE TABLE IT_DISPLAY.
      IF SY-TFILL > 0.
      SET PF-STATUS 'STANDARD'.
      ENDIF.
      ENDIF.
      IF W_MODE = 'DISPLAY'.
      SET PF-STATUS 'STANDARD' EXCLUDING IT_EXCLUDE.
      ENDIF.
    IF ZACT02_BOXKOD-MASTER_PATTERN IS NOT INITIAL AND
       ZACT02_BOXKOD-PATTERNSLNO    IS NOT INITIAL.
    LOOP AT SCREEN.
    IF SCREEN-GROUP1 = 'TOP'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    IF W_MODE = 'DISPLAY'.
    IF ZACT02_BOXKOD-VERSNO IS INITIAL.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ZACT02_BOXKOD-VERSNO'.
    SCREEN-INPUT = 1.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ELSE.
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'ZACT02_BOXKOD-VERSNO'.
    SCREEN-INPUT = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDIF.
    ENDMODULE.                 " STATUS_0101  OUTPUT
    *&      Module  USER_COMMAND_0102  INPUT
          text
    MODULE USER_COMMAND_0102 INPUT.
    SAVE_OK = OK_CODE.
    CLEAR OK_CODE.
    CASE SAVE_OK.
    WHEN 'ADD'.
    DESCRIBE TABLE IT_DISPLAY.
    IF SY-TFILL >= TABC-LINES.
    IF TABC-LINES < 16.
    TABC-LINES = SY-TFILL + 1.
    ENDIF.
    ENDIF.
    WHEN 'DEL'.
    LOOP AT IT_DISPLAY INTO WA_DISPLAY WHERE MARK = 'X'.
    DELETE IT_DISPLAY INDEX SY-TABIX.
    ENDLOOP.
    DESCRIBE TABLE IT_DISPLAY.
    IF SY-TFILL >= 1.
    TABC-LINES = SY-TFILL.
    ELSE.
    TABC-LINES = 1.
    ENDIF.
    WHEN 'CHECK'.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~DUP_CHECK EXPORTING IT_C_DISPLAY = IT_DISPLAY.
    WHEN 'SAVE'.
    W_TIMLO = SY-TIMLO.
    IF W_MODE = 'CREATE'.
    PERFORM CREATE_SAVE.
    ENDIF.
    IF W_MODE = 'CHANGE'.
    PERFORM EDIT_SAVE.
    ENDIF.
    ENDCASE.
    IF W_MODE = 'DISPLAY'.
    SAVE_OK = 'CHECK'.
    ENDIF.
    ENDMODULE.                 " USER_COMMAND_0102  INPUT
    *&      Module  MOD_TABLE  INPUT
          text
    MODULE MOD_TABLE INPUT.
    CALL METHOD CL_TABLE_CONTROL=>M2 EXPORTING ZACS018_STR_C = ZACS018_STR CHANGING IT_C_DISPLAY = IT_DISPLAY.
    ENDMODULE.                 " MOD_TABLE  INPUT
    *&      Module  ASSIGN  OUTPUT
          text
    MODULE ASSIGN OUTPUT.
    CALL METHOD CL_TABLE_CONTROL=>M1 EXPORTING WA_C_DISPLAY = WA_DISPLAY IMPORTING ZACS018_STR_C = ZACS018_STR.
    ENDMODULE.                 " ASSIGN  OUTPUT
    *&      Module  CHK_PARTCODE  INPUT
          text
    MODULE CHK_PARTCODE INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~PARTNO_VAL EXPORTING PARTCODE = ZACS018_STR-PARTCODE.
    ENDMODULE.                 " CHK_PARTCODE  INPUT
    *&      Module  CHK_CAVITY  INPUT
          text
    MODULE CHK_CAVITY INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~CAVITY_VAL EXPORTING CAVITY = ZACS018_STR-CAVITY.
    ENDMODULE.                 " CHK_CAVITY  INPUT
    *&      Module  CHK_MAINB  INPUT
          text
    MODULE CHK_MAINB INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~MAINBI_VAL EXPORTING MAINB = ZACS018_STR-MAINB.
    ENDMODULE.                 " CHK_MAINB  INPUT
    *&      Module  GET_COMP_WT  INPUT
          text
    MODULE GET_COMP_WT INPUT.
    IF W_MODE <> 'DISPLAY'.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~GET_COMP_WT EXPORTING PARTCODE = ZACS018_STR-PARTCODE
                                              IMPORTING GROSSWT  = ZACS018_STR-GROSSWT.
    ENDIF.
    ENDMODULE.                 " GET_COMP_WT  INPUT
    *&      Module  CHK_NETWT  INPUT
          text
    MODULE CHK_NETWT INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~NETWT_VAL EXPORTING NETWT = ZACS018_STR-NETWT
                                                    GROSSWT = ZACS018_STR-GROSSWT.
    ENDMODULE.                 " CHK_NETWT  INPUT
    *&      Module  CHK_MPAT  INPUT
          text
    MODULE CHK_MPAT INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~MASPAT_VAL EXPORTING MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN.
    ENDMODULE.                 " CHK_MPAT  INPUT
    *&      Module  CHK_SLNO  INPUT
          text
    MODULE CHK_SLNO INPUT.
    IF W_MODE = 'CREATE'.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~PATSLNO_VAL EXPORTING PATTERNSLNO = ZACT02_BOXKOD-PATTERNSLNO
                                  MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN .
    ELSEIF W_MODE = 'CHANGE' .
    CALL METHOD O_CONTROL_EVENTS_EDIT->PATSLNO_VAL_CHG EXPORTING PATTERNSLNO = ZACT02_BOXKOD-PATTERNSLNO
                                  MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN .
    CALL METHOD O_CONTROL_EVENTS_EDIT->GET_DATA EXPORTING MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN
                                  PATTERNSLNO = ZACT02_BOXKOD-PATTERNSLNO
                                  IMPORTING VERSNO  = ZACT02_BOXKOD-VERSNO
                                  CHANGING ZACT02_BOXKOD = ZACT02_BOXKOD
                                           IT_C_DISPLAY  =  IT_DISPLAY
                                           IT_DEL_DISPLAY = IT_DEL_DISPLAY
                                           TABC          = TABC.
    ELSE.
    CALL METHOD O_CONTROL_EVENTS_DISPLAY->PATSLNO_VAL_CHG EXPORTING PATTERNSLNO = ZACT02_BOXKOD-PATTERNSLNO
                                  MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN .
    ENDIF.
    ENDMODULE.                 " CHK_SLNO  INPUT
    *&      Module  MAX_VER  INPUT
          text
    MODULE MAX_VER INPUT.
    IF W_MODE = 'CREATE'.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~MAX_REF IMPORTING VERSNO = ZACT02_BOXKOD-VERSNO.
    ENDIF.
    IF W_MODE = 'DISPLAY'.
    IF ZACT02_BOXKOD-VERSNO IS INITIAL.
    MESSAGE TEXT-023 TYPE 'E'.
    ENDIF.
    IF ZACT02_BOXKOD-MASTER_PATTERN IS NOT INITIAL AND
        ZACT02_BOXKOD-PATTERNSLNO IS NOT INITIAL AND
        ZACT02_BOXKOD-VERSNO IS NOT INITIAL.
    CALL METHOD O_CONTROL_EVENTS_DISPLAY->GET_DISPLAY_DATA EXPORTING MASTER_PATTERN = ZACT02_BOXKOD-MASTER_PATTERN
                                  PATTERNSLNO = ZACT02_BOXKOD-PATTERNSLNO
                                  VERSNO  = ZACT02_BOXKOD-VERSNO
                                  CHANGING ZACT02_BOXKOD = ZACT02_BOXKOD
                                           IT_C_DISPLAY  =  IT_DISPLAY
                                           TABC          = TABC.
    ENDIF.
    ENDIF.
    ENDMODULE.                 " MAX_VER  INPUT
    *&      Module  CHK_NOBOXES  INPUT
          text
    MODULE CHK_NOBOXES INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~NOOFBOX_VAL EXPORTING BMSCH = ZACT02_BOXKOD-BMSCH.
    ENDMODULE.                 " CHK_NOBOXES  INPUT
    *&      Module  CHK_TOTTIME  INPUT
          text
    MODULE CHK_TOTTIME INPUT.
    CALL METHOD O_CONTROL_EVENTS->I_DATA~TOTTIME_VAL EXPORTING VGW01 = ZACT02_BOXKOD-VGW01.
    ENDMODULE.                 " CHK_TOTTIME  INPUT
    *&      Module  STATUS_0100  OUTPUT
          text
    MODULE STATUS_0100 OUTPUT.
      SET PF-STATUS 'INITIAL'.
      SET TITLEBAR 'STANDARD_MAIN'.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  EXIT_PROGRAM  INPUT
          text
    MODULE EXIT_PROGRAM INPUT.
    LEAVE TO TRANSACTION 'ZAC16'.
    ENDMODULE.                 " EXIT_PROGRAM  INPUT

  • Reusing Standard Classes for Module pool Programming using Abap Objects

    Hi.,
        I debugged the ME21n transaction and found a number of classes such as
             CL_BASIC_MODEL_VIEW_MM
             CL_GENERIC_MODEL_VIEW_MM
             CL_GENERIC_VALUE_MODEL_MM
             CL_MODEL_CONTAINER_MM
             CL_MODEL_CONTROL_VIEW_MM
             CL_MODEL_VIEW_MM
             CL_TABLE_MODEL_MM
             CL_TABLE_MODEL_TREE_VIEW_MM
             CL_VALUE_MODEL_MM
             CL_VALUE_MODEL_VIEW_MM
             CL_BASIC_MODEL_VIEW_MM
            CL_COMPOSITE_SCREEN_VIEW_M
            CL_CUSTOM_CONTROL_VIEW_MM
            CL_EXPAND_BUTTON_VIEW_MM
            CL_EXPAND_VIEW_MM
            CL_FOREIGN_APPLICATION_VIE
            CL_GENERIC_MODEL_VIEW_MM
            CL_GRID_VIEW_MM
            CL_MODEL_CONTROL_VIEW_MM
           CL_MODEL_VIEW_MM
           CL_SCREEN_VIEW_MM
          CL_SETUPVIEW_BUILDER_MM
            CL_SIMPLE_TREE_VIEW_MM
             CL_TABLE_MODEL_TREE_VIEW_M
             CL_TABLE_VIEW_CONTAINER_MM
             CL_TABLE_VIEW_MM
             CL_TABSTRIP_VIEW_MM
             CL_TC_BUTTON_VIEW_MM
             CL_TC_ITEM_VIEW_MM
             CL_TOGGLE_VIEW_MM
             CL_VALUE_MODEL_VIEW_MM
             CL_DEFAULT_CONTROLLER_MM
             CL_CONTROLLER_MM
             CL_ATP_CONTROLLER_MM
             CL_DRAG_DROP_CONTROLLER_MM  ..
                   How we can reuse these classes to build a custom module pool program which supports MVC architecture as used in enjoy SAP transactions .I am very much confused from where to start .
    Guide me on this.I want to create a simple module pool program with Subscreens, Table Controls and Tabstrips ..
    Regards.,
    S.Sivakumar

    Have you got any solution on this.
    because i want to use CL_GRID_VIEW_MM->handle_on_data_changed for one of my development related to ME51N.

  • Creating module pool programming in abap objects

    Hello...
    I just wanted to know how u create a give modulepool programming in classes and objects.Could anyone tell me the procedure how to do so.And i knew that module pool programming has become obsolete and now everyone are using object oriented concept in module pool programming.soo i want why r they using soo and what is the drawback in using the module pool programming instead of oops concepts.Could anyone give me the clear explanation..

    Hello Chadipriya,
    You can create module pool program for both ABAP and ABAP OO(Object Oriented).
    The thing is in OO u have to declare classes,objects and methods.
    <b>Procedure oriented approach</b>
    1. Emphasis on tasks
    2. Large programs are divided into smaller programs known as functions
    3. Most of the functions share global data
    4. Data move openly around the system from function to function
    <b>Object oriented approach</b>
    Emphasis on things that does those tasks
    Programs are divided into objects
    3.    Data structures are designed such that they characterized the objects
    4.    Functions that operate on the data of an object are tied together in the data structure
    5.    Data can be hidden and cannot be accessed by external functions
    6.    New data and functions can be easily added whenever necessary
    Go to SE80 ---> Select Program ---> Give ur program name and type this code below :-
    REPORT  YSUBDEL LINE-SIZE 120.
    CLASS parentclass DEFINITION .
    PUBLIC SECTION.
      DATA : commondata(30) type c value 'Accessible to all'.
      METHODS : SHOWVAL.
    PROTECTED SECTION.
      DATA : protectdata(40) type c value 'Protected data'.
    private section.
    data : privatedata(30) type c value 'Private data'.
    ENDCLASS.
    CLASS parentclass IMPLEMENTATION.
    METHOD : SHOWVAL.
      write:/5 'All data from parentclass shown:-'.
      write:/ sy-uline.
      WRITE:/5 COMMONDATA,
            /5 PROTECTDATA,
            /5 PRIVATEDATA.
    endmethod.
    endclass.
    CLASS childclass DEFINITION INHERITING FROM parentclass.
    PUBLIC SECTION .
    METHODS : subval.
    ENDCLASS.
    CLASS childclass IMPLEMENTATION.
    method : subval.
      skip 1.
      write:/5 'Data of parent shown from child-'.
      write:/5 sy-uline.
      WRITE:/5 COMMONDATA,
            /5 PROTECTDATA.
      Commondata = 'Public data changed in subclass'.
      Protectdata = 'Protected data changed in subclass'.
      write:/5 sy-uline.
      WRITE:/5 COMMONDATA,
            /5 PROTECTDATA.
    endmethod.
    endclass.
    You r using OOPs concepts in module pool program and not  module pool programming instead of oops concepts.
    <b>Reward points if helpful</b>
    Thanks,
    Sachin

  • How to take backup of an entire module pool program with code,screen,etc.

    Hi experts,
    I have some important data in the ides server for which i want to take backup of them.
    I have some question regarding the same.
    1.How to take backup/download of an entire module pool program with code,screen,etc.
    2.How can we take backup/download for a DB table with its structure?
    3.How can we take backup of a search help?
    Please give some suggestions abt the same.
    Regards,
    Ashesh.

    Hi,
    May be just for viewing, try downloading from SE80 transaction from the others option.
    Here just try issuing the print, it will generate the spool.
    Now using the spool, download to your desktop as required. It will have all the information regarding the attributes, fields, elements everything.
    The only issue is, may be you need to take all the screens separately.
    Regards,
    Santhosh.

  • Call report selection screen in module pool program with tab strip control

    Hi,
    Could anyone explain in detail to call report selection screen in module pool program with tab strip control.
    Thanks
    Mano

    Hi,
    Refer std program:
    demo_sel_screen_in_tabstrip.
    demo_sel_screen_with_tabstrip.
    Call your program with SUBMIT stmt form module program.
    Reward points if this Helps.
    Manish

  • Who has the book:Object-Oriented Programming with ABAP Objects

    Hello everyone
    Now i want to learn ABAP OO,and Lots' of guys told me that the book  Object-Oriented Programming with ABAP Objects is realy a good book.but i searched on the net,and could not got PDF of this book,could some one gave me the net address if you know where to download the book or send me to my Mailbox:<email id removed by moderator>,I will very glad to receive any response from you,
    of course,if you have some advise on how to learn ABAP OO or some other material ,hope you could share your meaning with me, hope to receive your response.
    Best regards!
    From Carl
    Moderator message : Moved to career center.
    Edited by: Vinod Kumar on Aug 27, 2011 9:21 AM

    I'm sure you're not asking for illegal, "free" downloads. You can legally purchase the book, also in electronic format, at sap-press.com
    Thomas

  • Module pool program with OOPS

    Hi friends,
    am working on module pool program i want to use oops concept in moduel pool.can any body give me an example in
    module pool with oops .
    Thanks in advance,
    sai.

    Hello,
    we have uses ABAP OO and Classic Dypros in our current projekt a lot.
    It turned out to be the best way to it like this:
    1. Create your Dynpro
    2. Create an Interface that corresponds only to that Dynpro.
    3. In the Modules of the dynpro you only  call Methods from that interface created above, also all checks of Dynprofields etc should be handled in the Implelmentation of the methods. so you do like that:
    Module set_vbeln.
       gi_dynp_class->set_vbeln( gs_sd-vbeln ).
    endmodul.
    gi_dynp_class is from type of your interface.
    4. Create an application class that implements all the methods of the interface with the logic needed.  Using inheritance you can easily reuse the the Dynpro in different contexts with different Application classes behind it.
    5. In PBO of the dynpro you have to make sure that the the variable gi_dynp_class is bound. So you will cast your application class instance to it:
    gi_dynp_class ?= gi_app_class.
    The application class must be instanciates at the beginning of the program before the dynpro is used.
    As a class can implement several interface you can enable you application class for as many dynpros as you want to.
    Hope that helps a bit ...
    Greetings from Hamburg

  • Module Pool Program(SAP-ABAP)

    Hi,
      I am trying to put CHAIN..ENDCHAIN logic in PAI module
      to validate screen.
      How sd i use CHAIN..ENDCHAIN ?
      Pls guide me with suitable example.
      I m waiting for ur reply........
    Thanx in Adv.
    Prabhas

    HI,
    See the thread:
    Re: Chain - Endchain  - Selection-Screen
    i copied the below data from SAPHELP for your sake,
    To ensure that one or more PAI modules are only called when several screen fields meet a particular condition, you must combine the calls in the flow logic to form a processing chain. You define processing chains as follows:
    CHAIN.
    ENDCHAIN.
    All flow logic statements between CHAIN and ENDCHAIN belong to a processing chain. The fields in the various FIELD statements are combined, and can be used in shared conditions.
    CHAIN.
    FIELD: <f1>, <f 2>,...
    MODULE <mod1> ON CHAIN-INPUT|CHAIN-REQUEST.
    FIELD: <g1>, <g 2>,...
    MODULE <mod2> ON CHAIN-INPUT|CHAIN-REQUEST.
    ENDCHAIN.
    The additions ON CHAIN-INPUT and ON CHAIN-REQUEST work like the additions ON INPUT and ON REQUEST that you use for individual fields. The exception is that the module is called whenever at least one of the fields listed in a preceding FIELD statement within the chain meets the condition. So <mod1> is called when one of the fields <fi> meets the condition. <mod2> is called when one of the fields <f i> or <g i> meets the condition.
    Within a processing chain, you can combine individual FIELD statements with a MODULE statement to set a condition for a single field within the chain:
    CHAIN.
    FIELD: <f1>, <f 2>,...
    FIELD <f> MODULE <mod1> ON INPUT|REQUEST|*-INPUT
    |CHAIN-INPUT|CHAIN-REQUEST.
    MODULE <mod2> ON CHAIN-INPUT|CHAIN-REQUEST.
    ENDCHAIN.
    The module <mod1> is called when screen field <f> meets the specified condition for individual fields. <mod2> is called when one of the fields <fi> or <f> meets the condition. If you use the addition ON CHAIN-INPUT or ON CHAIN-REQUEST with FIELD <f>, the condition also applies to the entire chain and module <mod1> and <mod2> are both called.
    <i>
    Check this out
    http://help.sap.com/saphelp_nw04/helpdata/en/9f/dbabbd35c111d1829f0000e829fbfe/content.htm
    http://help.sap.com/saphelp_47x200/helpdata/en/d1/801ca2454211d189710000e8322d00/frameset.htm</i>
    Regards
    anver
    Message was edited by: Anversha s

  • Debugging a Module Pool Program(Object Oriented ABAP)

    Hello Experts,
    Could you please advise me on an efficient debugging technoque of Module Pool Program which is based on Object Oriented ABAP?

    Hi
    Debugging Module pool program using ABAP objects is same as debugging any other report/module pool program.
    Click on the Create shortcut icon on the toolbar.
    In the popup window choose "System command" and in the command enter "/h"
    A shortcut on the desktop would be created
    Drag and drop the shortcut to the modal window to set debugging on.
    Approach 2:
    Create a txt file on the desktop with the following lines:
    [FUNCTION]
    Command=/H
    Title=Debugger
    Type=SystemCommandDrag and drop this file to the modal window to set debugging on.
    How do I switch between the Classic and New Debugger
    From within the ABAP workbench, select the Utilities->Settings Menu
    Select the ABAP Editor Tab
    Select the Debugging tab within the ABAP Editor Tab
    Select the Classic Debugger or New Debugger radio button
    Refer to this thread
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    Debugging
    Check these documents.
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_nw04/helpdata/en/5a/4ed93f130f9215e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/84/1f624f4505144199e3d570cf7a9225/frameset.htm
    http://help.sap.com/saphelp_bw30b/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    ABAP Debugging
    http://www.saplinks.net/index.php?option=com_content&task=view&id=24&Itemid=34
    Look at the SAP help link below
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    Reward points if useful
    Regards
    Anji

  • How to write module pool program

    hai,
    what is the module -pool program ?
    what are the procedures to write the module-pool program.
    plz give the simple program for module-pool programs?
    regards
    surender

    Hi
    This component though is not attached to the screen painter, plays important role in transaction. Normally, for reports, on line executable programs are written but for transaction, Module Pool Programs are written. The module pool program contains only modules to handle various events associated with screen and data declaration statements.
    System divides the module pool program into several include program. These are global field, PBO modules, and PAI modules. It is entirely user’s decision whether to use these modules or write directly into main program.
    Creation of Module Pool Program
    You can create module pool program either through
    Object browser
    System automatically creates the module pool program and for these program which are created through object browser, system creates the include modules.
    Or
    ABAP/4 editor
    It is similar to normal program creation. Type of program should be given ‘M’ and is not created by system.
    Communication between Dynpro and Module Program
    For each screen, the system executes the flow logic, which contains corresponding events. The control is passed to Module Pool Program. Module Pool Program handles the code for these events and again passes back control to the flow logic and finally to screen. Unlike on line program, in this case, the control remains with flow logic. The switching of control between flow logic and module pool program and back is common process when user executes transaction.
    Creation of a Complete Transaction
    Steps involved to create a complete transaction
    •     Create module pool program.
    •     From screen painter create screens.
    •     Write flow logic for each screen.
    •     Write code for all the events in module pool program.
    •     Check for any error in screen and flow logic.
    •     Generate each and every component of screen i.e. flow logic and screen.
    •     Single screen can be tested using Screen Painter.
    •     Create transaction code through object browser.
    •     Generate the transaction code.
    •     User can execute the transaction by entering the transaction code in the command field.
    Handling Function Code
    The function code or OKCODE is the last field of Field list. Function code can be handled as follows:
    During the Designing of the screen, a function code is assigned to pushbutton.
    •     In field list, developer needs to specify OKCODE as last field.
    •     In module program it is a global field and can be evaluated in the PAI event.
    •     A function code is treated in the same way, regardless it comes from pushbutton, menu item or any other GUI element.
    When the user clicks on the Display button, you want to display details of sflight, with corresponding carrid and connid (which is entered by the user).
    Module pool program to handle this particular screen is as follows:
    Program YVTEST7.
    TABLES: SFLIGHT.
    DATA: OKCODE (4).
    MODULE INPUT1 INPUT,
    CASE OKCODE.
       WHEN ‘DISP’.
         SELECT * FROM SFLIGHT
                WHERE CARRID =  SFLIGHT – CARRID AND
                               CONNID = SFLIGHT – CONNID.
         ENDSELECT.
         LEAVE TO SCREEN 200.
       WHEN ‘EXIT’.  LEAVE TO SCREEN 0.
      ENDCASE.
    ENDMODULE.               “INPUT1 INPUT
    MODULE USER_COMMAND_0200 INPUT.
    CASE OKCODE.
    WHEN ‘BACK’. LEAVE TO SCREEN 100.
    ENDCASE.
    ENDMODULE.                    “USER_COMMAND_0200 INPUT
    When the user clicks on display, control is transferred to screen no. 200 on which you display sflight details & on the same screen, when user clicks on BACK button, he comes back to main screen.
    Flow logic for screen 100 is as follows:
    PROCESS AFTER INPUT.
    MODULE INPUT.
    Flow logic for screen 200
    PROCESS AFTER INPUT.
    USER_COMMAND_0200.
    MODULES: Modules are handled in module pool program.
    You need to write flow logic for screen 200 and design screen 200.
    In case of transaction transfer of data from program to screen is automatic i.e. you need not transfer the data from program to screen explicitly. The fields, which you define in the screen receives the data from program and displays the same.
    The Field Checks
    As already mentioned Transaction is the only method, which SAP recommends to update the database tables. Data entered in the database table should be valid and correct. Data entered is validated at each and every point. ABAP/4 offers various methods to validate data and those are as follows:
    •     Automatic field checks
    •     Checks performed in the flow logic
    •     Checks performed in the ABAP/4 module pool program
    Automatic Field Checks
    These checks are based on the field information stored in the dictionary. These checks are performed by the system automatically when the user enters the data for the screen field. System performs these checks before PAI event is triggered. Types of field checks performed by system are as follows:
    •     Required input
    While designing the screen, for particular screen field if you click the Req. Entry checkbox, the field becomes mandatory. When the transaction is executed if user leaves this particular field blank, the system displays error message. User cannot proceed until the user enters some data.
    •     Proper Data Format
    Each field has its own data format whether it is table field or screen field. Whenever data is entered, system checks for the proper format of the data. For example date. Each user has its own format for date, which is defined in the user master record. If the date defined in the user master record is in the format DD/MM/YYYY, if the user enters the date, say, in YY/DD/MM, the user displays the error message. System also checks for the value of month or days. For example if month entered is greater than twelve then the error message is displayed.
    •     Valid Value for the Field
    In data dictionary two tables are related by Primary key-Foreign key relationship.  Whenever the user enters the data, the system checks for the check table values.   Also in Domain, if you have fixed values, then the system checks for these values.
    Automatic field checks are repeated each time the user enters the data.
    About at Exit – Command
    Automatic field checks can be avoided by AT EXIT-COMMAND, which works exactly the same way as Cancel works on application tools bar. In the R/3 screen, if you want to quit the processing of that particular screen without entering the mandatory fields, user can click the Cancel button. Same functionality can be incorporated in the user-defined transaction by using AT EXIT-COMMAND. This module can be called before the system executes the automatic field checks and it goes without saying that before PAI event. Code for AT EXIT-COMMAND in flow logic and in module pool program can be written as follows:
    In Flow Logic
    Process After Input.
    Module exit AT EXIT-COMMAND.
             In module pool program.
    Module exit.
    Case okcode.
    When ‘Exit’.
    Leave to screen 0.
    To achieve this kind of functionality a pushbutton or menu item should be assigned a function type ‘E’. It tells the system to process this particular module before carrying out any field checks.
    Flow Logic Validations
    Consider the case where you want user to enter only ‘LH’ and ‘SQ’ for sflight-carrid. In this case, you are restricting value of a screen field. This cannot be achieved by automatic field check. Hence there is a need of additional validation. It can be done in flow logic by using following statement:
    Field -
    Values
    Syntax
    PAI.
    Field sflight-carrid values (‘LH’).
    For multiple values
    PAI.
    Field sflight-carrid values (‘LH’ ‘SQ’).
    Field sflight-price values (between 1000 and 2000).
    In this case when the user enters the value, PAI is triggered  and field is checked for  that particular value. If the value entered happens to be wrong, that field is enabled for user to enter. If you have multiple Field statements in your flow logic, it is sequential execution.
    Consider the following case:
    PAI.
    Module  assign.
    Field sflight-carrid values (‘LH’ ‘SQ’).
    In ABAP/4
    Module  assign.
    Data: carrid1 like sflight-carrid.
    Carrid1 = sflight-carrid.
    Endmodule.
    In this case, Sflight-carrid is used in the flow logic before the field statement. The system will give invalid value or some previous value as the field sflight-carrid is used in module before it is checked i.e., field statement is after the module in which sflight-carrid is being used. The field is not available to the system unless it executes the field statement. Field statement transfers the values to the program and is done only once. If you don’t have Field statement in your flow logic, transfer of values takes place in PAI event.
    Consider one more case where you have multiple field statement
    PAI.
    Field Sflight-carrid values (‘LH’).
    Field Sflight-connid values (‘0400’ ‘0500’).
    In this case if the user enters only carrid wrong, then this particular field is enabled and rest of the fields are disabled for user to input. Many times if the user enters wrong value for one field, then you might want to give option to user to enter all the fields, which is not possible by using Field statement only. This functionality can be achieved by CHAIN – ENDCHAIN.
    Syntax
    Chain.
    Field sflight-carrid value (‘LH’).
         Field sflight-connid values (between ‘200’ and ‘500’).
    Endchain.
    Field sflight-price values (‘100’ ‘1000’).
    In this case, if the user enters wrong value only for carrid, both the fields i.e. carrid and connid are enabled as they are grouped together in the Chain statement. The field price will be disabled for input. Usually, logically related fields are grouped together with Chain-Endchain statement.
    Module Pool Program Validations
    Checking fields ABAP/4 program includes
    •     Field statement in flow logic.
    •     Module statement in ABAP/4 module pool Program.
    Syntax
    PAI.
    Field sflight-carrid module <name>.
    This module can be handled in the main program i.e. module pool program.
    In ABAP/4 program
    Module Check.
    Select single * from sflight where carrid = sflight-carrid.
    If sy-subrc ne 0.
         Message e001.
    Endif.
    In this case, field sflight-carrid is checked in the table for its existence.
    Dynamically Calling the Screens
    About Displaying Next Screen
    Transaction is a sequence of screens, which are displayed one after the other. The next screen displayed depends upon the attributes of first screen. In attributes you need to give Next Screen number i.e. if next screen displayed should be 200 screen, then this number should be given in next Screen attributes. These are static attributes of the screen. By default, if nothing is specified in the program, the system branches out to the screen number, which is specified in the attribute screen.
    In this case, if user selects MARA pushbutton, then fields from Mara table are displayed. When the user clicks on the MARD, then the fields from MARD table are displayed. Depending upon users selection, the screen is branched out and this has to be done during runtime. This functionality can be achieved by dynamically calling the screen in module pool program.
    The screen can branch out to new screen depending upon user selection. Following command in module pool program can do this:
    •     SET SCREEM
    •     CALL SCREEN
    •     LEAVE TO SCREEN <NUMBER>
    All these commands override the specifications given in the attributes. This overriding is temporary. The values stored in the attribute are not changed.
    Set Screen
    Syntax
    Set screen <number>.
    In module pool program
    Case okcode.
         When  ‘DISP’.
              Set screen 200.
         When ‘LIST’.
              Set screen 300.
    Endcase.
    In this case, the entire processing of current screen takes place and then the system branches out to next screen. If you want to branch out to the next screen without processing the current screen, LEAVE SCREEN should be used along with the SET SCREEN.
    For Example:
    Case okcode..
         When  ‘DISP’.
              Set screen 200.
              Leave Screen.
         When ‘LIST’.
              Set screen 300.
              Leave Screen.
    Endcase.
    When SET SCREEN is used, control cannot be transferred to the main screen or previous screen, unless you write code for the same.
    Call Screen
    Usually used for pop up screens. Many times, there is a need for user to enter additional information or secondary information on another screen or pop up screen. Once the user enters the data, he should be able to go back to main screen or to the screen where he started. This is not possible by using SET SCREEN. CALL SCREEN achieves this functionality.
    Syntax
    Call Screen 200.
    Will simply call a screen number 200 from a main screen. Once the screen is displayed the user can enter all the data and return to the main screen by clicking BACK button.
    To call screen as pop up screen the syntax is
    Call screen starting at <col.no.> <line no>
                         Ending at <col no> <line no>.
    In this case window will be popped as window and user can close it by using BACK button.
    Leave to screen
    To SET a new screen without processing current screen, you need to use the following two statements together:
    SET SCREEN 200.
    LEAVE SCREEN.
    Or a Single statement
    LEAVE TO SCREEN 200.

  • Renaming a Module pool program

    Hi Friends,
    How to change the name of the Module pool program coz I created a module pool program with the name SAPMZ_XYZ and the includes are created starting with MZ_XYZ and my basis consultant is not accepting the includes starting with MZ.
    When I tried to change the name of the module pool program it is asking me the access key.
    Regards,
    Line

    - Does your basis consultant say someting on function group, main program starting with SAPLZ and not Z (strictly inadmissible )
    - Also give him the reference Note 16466 - Customer name range for SAP objects
                              |Transp.  |Length |                     |As of
    Object                    |object   |of name| Customer name range |Rel.
                              |         |3.*/4.*|                     |
    --------------------------|---------|-------|---------------------|----
    Module pool screen        |R3TR PROG| 8/30  |  SAPMY* SAPMZ*       |
    Regards,
    Raymond
    Oops, did not notice the date of original post...

  • Error in module pool program

    Hi All,
    I have created 1 module pool program with screen no. 0100. But the statement CALL SCREEN 0100 is not getting executing its showing error i.e ' statement cannot be accessable' even i have created and activated the sceen 0100.
    Thanks...
    kiran

    Hi kiran,
    Open you program in se38 menu bar -> GOTO   -> ATTRIBUTES and check wheather it is  executable program or module pool program.
    if it is exeutable program then u can call the screen 0100 as ur intial screen. if not ur given type as module pool then u have to create a transaction in SE93 and give the screen name in that and prgoram name then it will display the screen which u hv created .
    if you want to show the screen 0100 as ur initial sceen in module pool program without using transaction it is not possible so use either executable program and use the stament call screen 0100.
    <b>reward if useful </b>
    Regards,
    sunil kairam.

  • Making a screen in module pool program web based

    I have developed a module pool program with screens and flow logic. I want to make that application web based. Is there any option to make it web based or I have to write the fresh application in bsp. Please suggest

    Sucheta,
    You unfortuantely need to re-write that application as BSP.  If you separated your business logic from the screen logic, then all you will need to do is rewrite the screen logic and not the whole application.
    Take care,
    Stephen

Maybe you are looking for

  • I can't read my email after upgrading to Tiger

    Hi, For some reason after I installed Tiger version 10.4.3 my email headers appear fine, but when I click on the header to read the email all I get is: "The message from _____ has not been downloaded from the server. You need to take this account onl

  • HP Solution Center won't work with Windows 7

    Are there any current workarounds to using the HP Solution Center (for scanning / faxing / printer) for HP Printers with Windows 7 ? I have an HP Photosmart C7280 (wireless), have installed, re-installed, un-installed, installed from hp.com, installe

  • Can't copy files to network drop box

    I'm running an Ubuntu server with netatalk (afp server) running and serving a couple afp shares. In one of the shares, I have a drop box directory that is owned by user "foo" and has group "bar". My Mac system username is "dude" and I also have a use

  • I'm trying to sign in on my account but an error sign come's up from window's saying test connection any ideas......

    I'm trying to sign in on my itunes account but windows error come's up saying test connection any ideas.....

  • EK01 & EK02 Condition Type

    Dear Friends In Sales Document type in Billing Section Condition Type Line Item=EK02 and In Standard Pricing Procedure RVAA01 used EK01 and EK02 What is the use of it where it will affect? Please clarify my doubts Thanking You Arun