How to access screen field value in a module pool programming?

Hi Experts,
   I have create a module pool program SAPMYDLG. It contains two screens 100 and 200.
   The first screen contains Employee_ID field. This field is not a dictionary field.
   In the second screen 200, I want to access the value of Employee_ID field from first screen.
   For this I created a global variable v_empid in TOP include.
   Then in the PAI of the screen 100 I have assigned the screen field value to global variable.
   v_empid = Employee_ID.
   But this gives an error saying " Field  Employee_ID not defined".
   What am I doing wrong? How can I access the screen field value?
Thanks
Gopal

Hi,
Employee_ID field also must u define in the top include when u define that 100 screen and 200 screen will access.
regards,
muralii

Similar Messages

  • How to make the field as mandatory in module pool program.

    Hi Experts,
    Could you please advice me in making a screen field as mandatory input field in module pool programming.
    Thanks in advance.

    Or you could add a check in a PAI module to check if there is some value, if not give error message.
    module check_value.
      if lv_value is initial.
        message e001(00) with 'Enter a value'.
      endif.
    endmodule
    In the PAI screen flow logic...
    Process after input.
    field lv_value module check_value.
    Regards,
    Rich Heilman

  • How to access screen field in pai event

    Hi All,
    I have created a custom screen it has the field say matnr selected from the dictionay.NOw  how will I should access this field in PAI event module?
    Thanks in advance
    Mahesh

    just declare the same variable in your abap editor as per your layout field name.
    suppose in your layout input field name is matnr just declare
    data : matnr like mara-matnr.
    in pai module if you are using matnr it will give you the screen data.
    like
    module pai input.
    if matnr ne '1000'.
    message 'Error matnr is not 1000' type 'E'.
    endif.
    endmodule.
    reagards
    shiba dutta

  • How to pass values to a module pool program from another Report Program

    Hi ..
    Please let me know how I can pass values to a MODULE POOL selection screen field from another Report Program.
    Thanks
    RK

    http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/frameset.htm

  • How to create selections-screens to display PO using module pool program

    All,
    I'm new to module pool programming. Can any one please provide me where to create selections screens to display existing purchase orders using the below selection criteria in thr module pool program.,
    SELECT-OPTIONS : S_LIFNR FOR EKKO-LIFNR,
                     S_BSART FOR EKKO-BSART,
                     S_BUKRS FOR EKKO-BUKRS,
                     S_WERKS FOR EKPO-WERKS OBLIGATORY,
                     S_BEDAT FOR SY-DATUM,
                     S_EINDT FOR EKET-EINDT,
                     S_EBELN FOR EKKO-EBELN,
                     S_MATNR FOR EKPO-MATNR.
    provide me step by step to do this.

    Hi,
    Thanks for the reply can you please let me know.
    How can I create the ranges
    like low and high in the selection.
    Using se51 i was able to do only one i,e
    example I need
    purchase order number----
    f4 -
    f4
    Can please tell me how to do this

  • How to change screen field value.

    Hi Experts,
             I like to change the screen field MSAUS(check box) of program SAPLIQS0 in one of the exit.But if I use
    (SAPLIQS0)VIQMEL-MSAUS = 'X'. its showing compile error.Please tell me how can i change this field in this exit.
    Regards,
    Ajish.

    try something like this:
    create field symbol
      FIELD-SYMBOLS: <fs>.
    Assign value of variable from calling prog to field symbol
      ASSIGN ('(SAPLIQS0)VIQMEL-MSAUS' ) TO <fs>.
    <fs> = 'X'.
    Regards,
    ravi

  • How to write select options with extension in module pool program

    hi,
    M having  the following fields through screen painter.
    1. sales offfice
    2.sales district
    3.customer no
    for those three fields no extension is not provided and no search help is there.
    i want write  seletion options to get extension in that module pool
    screen.
    plese send coding for me , please let me know how to get that
    select options with the above all three fields.
    Thanks & Regards
    Raji

    Check it
    In top include
    DATA: number(4) TYPE n VALUE '9005',
    PROCESS BEFORE OUTPUT.
      MODULE status_9001.
      CALL SUBSCREEN AREA1 INCLUDING SY-REPID number.
    PROCESS AFTER INPUT.
      MODULE user_command_9001.
      CALL SUBSCREEN AREA1.
    *&      Module  status_9001  OUTPUT
          text
    MODULE status_9001 OUTPUT.
      SELECTION-SCREEN BEGIN OF SCREEN 9005 AS SUBSCREEN.
      PARAMETER pa_bukrs TYPE t001-bukrs.
      select-options matnr for wa_matnr.
      SELECTION-SCREEN END OF SCREEN 9005.
    ENDMODULE.                 " status_9001  OUTPUT

  • 'how to code for table control wizard in module pool program

    Hi Gurus,
    Please provide me a sample code of table control wizard...
    Thanks in advance!!!!
    Regards,
    Kranthi

    Hi Kranti,
    check this code... it should be helpful
    *& Module pool       Z_TABLE_CONTROL_WIZARD_DEMO                       *
    PROGRAM  z_table_control_wizard_demo             .
    DATA: BEGIN OF lt_vbak OCCURS 0,
           flag  TYPE c,
           vbeln TYPE vbeln_va,
           netwr TYPE netwr,
           kunnr TYPE kunnr,
          END OF lt_vbak.
    DATA: sfkunnr TYPE kunnr.
    *&spwizard: declaration of tablecontrol 'TCONTROL' itself
    CONTROLS: tcontrol TYPE TABLEVIEW USING SCREEN 9000.
    *&spwizard: lines of tablecontrol 'TCONTROL'
    DATA:     g_tcontrol_lines  LIKE sy-loopc.
    DATA:     ok_code LIKE sy-ucomm.
    *&spwizard: output module for tc 'TCONTROL'. do not change this line!
    *&spwizard: update lines for equivalent scrollbar
    MODULE tcontrol_change_tc_attr OUTPUT.
      DESCRIBE TABLE lt_vbak LINES tcontrol-lines.
    ENDMODULE.                    "TCONTROL_change_tc_attr OUTPUT
    *&spwizard: output module for tc 'TCONTROL'. do not change this line!
    *&spwizard: get lines of tablecontrol
    MODULE tcontrol_get_lines OUTPUT.
      g_tcontrol_lines = sy-loopc.
    ENDMODULE.                    "TCONTROL_get_lines OUTPUT
    *&spwizard: input module for tc 'TCONTROL'. do not change this line!
    *&spwizard: modify table
    MODULE tcontrol_modify INPUT.
      MODIFY lt_vbak
        INDEX tcontrol-current_line.
    ENDMODULE.                    "TCONTROL_modify INPUT
    *&spwizard: input modul for tc 'TCONTROL'. do not change this line!
    *&spwizard: mark table
    MODULE tcontrol_mark INPUT.
      DATA: g_tcontrol_wa2 LIKE LINE OF lt_vbak.
      IF tcontrol-line_sel_mode = 1.
        LOOP AT lt_vbak INTO g_tcontrol_wa2
          WHERE flag = 'X'.
          g_tcontrol_wa2-flag = ''.
          MODIFY lt_vbak
            FROM g_tcontrol_wa2
            TRANSPORTING flag.
        ENDLOOP.
      ENDIF.
      MODIFY lt_vbak
        INDEX tcontrol-current_line
        TRANSPORTING flag.
    ENDMODULE.                    "TCONTROL_mark INPUT
    *&spwizard: input module for tc 'TCONTROL'. do not change this line!
    *&spwizard: process user command
    MODULE tcontrol_user_command INPUT.
      ok_code = sy-ucomm.
      PERFORM user_ok_tc USING    'TCONTROL'
                                  'LT_VBAK'
                                  'FLAG'
                         CHANGING ok_code.
      sy-ucomm = ok_code.
    ENDMODULE.                    "TCONTROL_user_command INPUT
    *   INCLUDE TABLECONTROL_FORMS                                         *
    *&      Form  USER_OK_TC                                               *
    FORM user_ok_tc USING    p_tc_name TYPE dynfnam
                             p_table_name
                             p_mark_name
                    CHANGING p_ok      LIKE sy-ucomm.
    *&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
      DATA: l_ok              TYPE sy-ucomm,
            l_offset          TYPE i.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
    *&SPWIZARD: Table control specific operations                          *
    *&SPWIZARD: evaluate TC name and operations                            *
      SEARCH p_ok FOR p_tc_name.
      IF sy-subrc <> 0.
        EXIT.
      ENDIF.
      l_offset = STRLEN( p_tc_name ) + 1.
      l_ok = p_ok+l_offset.
    *&SPWIZARD: execute general and TC specific operations                 *
      CASE l_ok.
        WHEN 'INSR'.                      "insert row
          PERFORM fcode_insert_row USING    p_tc_name
                                            p_table_name.
          CLEAR p_ok.
        WHEN 'DELE'.                      "delete row
          PERFORM fcode_delete_row USING    p_tc_name
                                            p_table_name
                                            p_mark_name.
          CLEAR p_ok.
        WHEN 'P--' OR                     "top of list
             'P-'  OR                     "previous page
             'P+'  OR                     "next page
             'P++'.                       "bottom of list
          PERFORM compute_scrolling_in_tc USING p_tc_name
                                                l_ok.
          CLEAR p_ok.
    *     WHEN 'L--'.                       "total left
    *       PERFORM FCODE_TOTAL_LEFT USING P_TC_NAME.
    *     WHEN 'L-'.                        "column left
    *       PERFORM FCODE_COLUMN_LEFT USING P_TC_NAME.
    *     WHEN 'R+'.                        "column right
    *       PERFORM FCODE_COLUMN_RIGHT USING P_TC_NAME.
    *     WHEN 'R++'.                       "total right
    *       PERFORM FCODE_TOTAL_RIGHT USING P_TC_NAME.
        WHEN 'MARK'.                      "mark all filled lines
          PERFORM fcode_tc_mark_lines USING p_tc_name
                                            p_table_name
                                            p_mark_name   .
          CLEAR p_ok.
        WHEN 'DMRK'.                      "demark all filled lines
          PERFORM fcode_tc_demark_lines USING p_tc_name
                                              p_table_name
                                              p_mark_name .
          CLEAR p_ok.
    *     WHEN 'SASCEND'   OR
    *          'SDESCEND'.                  "sort column
    *       PERFORM FCODE_SORT_TC USING P_TC_NAME
    *                                   l_ok.
      ENDCASE.
    ENDFORM.                              " USER_OK_TC
    *&      Form  FCODE_INSERT_ROW                                         *
    FORM fcode_insert_row
                  USING    p_tc_name           TYPE dynfnam
                           p_table_name             .
    *&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
      DATA l_lines_name       LIKE feld-name.
      DATA l_selline          LIKE sy-stepl.
      DATA l_lastline         TYPE i.
      DATA l_line             TYPE i.
      DATA l_table_name       LIKE feld-name.
      FIELD-SYMBOLS <tc>                 TYPE cxtab_control.
      FIELD-SYMBOLS <table>              TYPE STANDARD TABLE.
      FIELD-SYMBOLS <lines>              TYPE i.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
      ASSIGN (p_tc_name) TO <tc>.
    *&SPWIZARD: get the table, which belongs to the tc                     *
      CONCATENATE p_table_name '[]' INTO l_table_name. "table body
      ASSIGN (l_table_name) TO <table>.                "not headerline
    *&SPWIZARD: get looplines of TableControl                              *
      CONCATENATE 'G_' p_tc_name '_LINES' INTO l_lines_name.
      ASSIGN (l_lines_name) TO <lines>.
    *&SPWIZARD: get current line                                           *
      GET CURSOR LINE l_selline.
      IF sy-subrc <> 0.                   " append line to table
        l_selline = <tc>-lines + 1.
    *&SPWIZARD: set top line                                               *
        IF l_selline > <lines>.
          <tc>-top_line = l_selline - <lines> + 1 .
        ELSE.
          <tc>-top_line = 1.
        ENDIF.
      ELSE.                               " insert line into table
        l_selline = <tc>-top_line + l_selline - 1.
        l_lastline = <tc>-top_line + <lines> - 1.
      ENDIF.
    *&SPWIZARD: set new cursor line                                        *
      l_line = l_selline - <tc>-top_line + 1.
    *&SPWIZARD: insert initial line                                        *
      INSERT INITIAL LINE INTO <table> INDEX l_selline.
      <tc>-lines = <tc>-lines + 1.
    *&SPWIZARD: set cursor                                                 *
      SET CURSOR LINE l_line.
    ENDFORM.                              " FCODE_INSERT_ROW
    *&      Form  FCODE_DELETE_ROW                                         *
    FORM fcode_delete_row
                  USING    p_tc_name           TYPE dynfnam
                           p_table_name
                           p_mark_name   .
    *&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
      DATA l_table_name       LIKE feld-name.
      FIELD-SYMBOLS <tc>         TYPE cxtab_control.
      FIELD-SYMBOLS <table>      TYPE STANDARD TABLE.
      FIELD-SYMBOLS <wa>.
      FIELD-SYMBOLS <mark_field>.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
      ASSIGN (p_tc_name) TO <tc>.
    *&SPWIZARD: get the table, which belongs to the tc                     *
      CONCATENATE p_table_name '[]' INTO l_table_name. "table body
      ASSIGN (l_table_name) TO <table>.                "not headerline
    *&SPWIZARD: delete marked lines                                        *
      DESCRIBE TABLE <table> LINES <tc>-lines.
      LOOP AT <table> ASSIGNING <wa>.
    *&SPWIZARD: access to the component 'FLAG' of the table header         *
        ASSIGN COMPONENT p_mark_name OF STRUCTURE <wa> TO <mark_field>.
        IF <mark_field> = 'X'.
          DELETE <table> INDEX syst-tabix.
          IF sy-subrc = 0.
            <tc>-lines = <tc>-lines - 1.
          ENDIF.
        ENDIF.
      ENDLOOP.
    ENDFORM.                              " FCODE_DELETE_ROW
    *&      Form  COMPUTE_SCROLLING_IN_TC
    *       text
    *      -->P_TC_NAME  name of tablecontrol
    *      -->P_OK       ok code
    FORM compute_scrolling_in_tc USING    p_tc_name
                                          p_ok.
    *&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
      DATA l_tc_new_top_line     TYPE i.
      DATA l_tc_name             LIKE feld-name.
      DATA l_tc_lines_name       LIKE feld-name.
      DATA l_tc_field_name       LIKE feld-name.
      FIELD-SYMBOLS <tc>         TYPE cxtab_control.
      FIELD-SYMBOLS <lines>      TYPE i.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
      ASSIGN (p_tc_name) TO <tc>.
    *&SPWIZARD: get looplines of TableControl                              *
      CONCATENATE 'G_' p_tc_name '_LINES' INTO l_tc_lines_name.
      ASSIGN (l_tc_lines_name) TO <lines>.
    *&SPWIZARD: is no line filled?                                         *
      IF <tc>-lines = 0.
    *&SPWIZARD: yes, ...                                                   *
        l_tc_new_top_line = 1.
      ELSE.
    *&SPWIZARD: no, ...                                                    *
        CALL FUNCTION 'SCROLLING_IN_TABLE'
             EXPORTING
                  entry_act             = <tc>-top_line
                  entry_from            = 1
                  entry_to              = <tc>-lines
                  last_page_full        = 'X'
                  loops                 = <lines>
                  ok_code               = p_ok
                  overlapping           = 'X'
             IMPORTING
                  entry_new             = l_tc_new_top_line
             EXCEPTIONS
    *              NO_ENTRY_OR_PAGE_ACT  = 01
    *              NO_ENTRY_TO           = 02
    *              NO_OK_CODE_OR_PAGE_GO = 03
                  OTHERS                = 0.
      ENDIF.
    *&SPWIZARD: get actual tc and column                                   *
      GET CURSOR FIELD l_tc_field_name
                 AREA  l_tc_name.
      IF syst-subrc = 0.
        IF l_tc_name = p_tc_name.
    *&SPWIZARD: et actual column                                           *
          SET CURSOR FIELD l_tc_field_name LINE 1.
        ENDIF.
      ENDIF.
    *&SPWIZARD: set the new top line                                       *
      <tc>-top_line = l_tc_new_top_line.
    ENDFORM.                              " COMPUTE_SCROLLING_IN_TC
    *&      Form  FCODE_TC_MARK_LINES
    *       marks all TableControl lines
    *      -->P_TC_NAME  name of tablecontrol
    FORM fcode_tc_mark_lines USING p_tc_name
                                   p_table_name
                                   p_mark_name.
    *&SPWIZARD: EGIN OF LOCAL DATA-----------------------------------------*
      DATA l_table_name       LIKE feld-name.
      FIELD-SYMBOLS <tc>         TYPE cxtab_control.
      FIELD-SYMBOLS <table>      TYPE STANDARD TABLE.
      FIELD-SYMBOLS <wa>.
      FIELD-SYMBOLS <mark_field>.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
      ASSIGN (p_tc_name) TO <tc>.
    *&SPWIZARD: get the table, which belongs to the tc                     *
      CONCATENATE p_table_name '[]' INTO l_table_name. "table body
      ASSIGN (l_table_name) TO <table>.                "not headerline
    *&SPWIZARD: mark all filled lines                                      *
      LOOP AT <table> ASSIGNING <wa>.
    *&SPWIZARD: access to the component 'FLAG' of the table header         *
        ASSIGN COMPONENT p_mark_name OF STRUCTURE <wa> TO <mark_field>.
        <mark_field> = 'X'.
      ENDLOOP.
    ENDFORM.                                          "fcode_tc_mark_lines
    *&      Form  FCODE_TC_DEMARK_LINES
    *       demarks all TableControl lines
    *      -->P_TC_NAME  name of tablecontrol
    FORM fcode_tc_demark_lines USING p_tc_name
                                     p_table_name
                                     p_mark_name .
    *&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
      DATA l_table_name       LIKE feld-name.
      FIELD-SYMBOLS <tc>         TYPE cxtab_control.
      FIELD-SYMBOLS <table>      TYPE STANDARD TABLE.
      FIELD-SYMBOLS <wa>.
      FIELD-SYMBOLS <mark_field>.
    *&SPWIZARD: END OF LOCAL DATA------------------------------------------*
      ASSIGN (p_tc_name) TO <tc>.
    *&SPWIZARD: get the table, which belongs to the tc                     *
      CONCATENATE p_table_name '[]' INTO l_table_name. "table body
      ASSIGN (l_table_name) TO <table>.                "not headerline
    *&SPWIZARD: demark all filled lines                                    *
      LOOP AT <table> ASSIGNING <wa>.
    *&SPWIZARD: access to the component 'FLAG' of the table header         *
        ASSIGN COMPONENT p_mark_name OF STRUCTURE <wa> TO <mark_field>.
        <mark_field> = space.
      ENDLOOP.
    ENDFORM.                                          "fcode_tc_mark_lines
    *&      Module  STATUS_9000  OUTPUT
    *       text
    MODULE status_9000 OUTPUT.
      SET PF-STATUS 'S9000'.
      SET TITLEBAR 'T9000'.
    ENDMODULE.                 " STATUS_9000  OUTPUT
    *&      Module  USER_COMMAND_9000  INPUT
    *       text
    MODULE user_command_9000 INPUT.
      CASE sy-ucomm.
        WHEN 'BACK' OR 'EXIT' OR 'CANCEL'.
          LEAVE TO SCREEN 0.
        WHEN 'DISP'.
          SELECT vbeln netwr kunnr INTO CORRESPONDING FIELDS OF TABLE lt_vbak
          FROM vbak
          WHERE kunnr = sfkunnr.
    *    LEAVE TO LIST-PROCESSING [AND RETURN TO SCREEN <nnnn>].
    *    By default, the dialog processor returns to the PBO processing of
    *    the screen from which the list processor was called. The optional
    *    addition AND RETURN TO SCREEN allows you to specify a different
    *    screen in the current screen sequence at whose PBO event you want
    *    to resume processing.
        when 'LIST'.
        LEAVE TO LIST-PROCESSING.
        WRITE:/ 'Time  :', SY-UZEIT.
        LOOP AT LT_VBAK.
        WRITE:/ LT_VBAK-VBELN,
                LT_VBAK-NETWR,
                LT_VBAK-KUNNR.
        ENDLOOP.
        WHEN 'SUBM'.
    *& You can call executable programs from other ABAP programs using the
    *& following statement:
    *& SUBMIT <rep>|(<field>) [AND RETURN] [<options>].
          SUBMIT z_submit_report VIA SELECTION-SCREEN AND RETURN.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_9000  INPUT
                                                     TABLE CONTROL WIZARD SE51 CODE
    PROCESS BEFORE OUTPUT.
    *&spwizard: pbo flow logic for tablecontrol 'TCONTROL'
      module TCONTROL_change_tc_attr.
    *&spwizard: module TCONTROL_change_col_attr.
      loop at   LT_VBAK
           with control TCONTROL
           cursor TCONTROL-current_line.
        module TCONTROL_get_lines.
    *&spwizard:   module TCONTROL_change_field_attr
      endloop.
    MODULE STATUS_9000.
    PROCESS AFTER INPUT.
    *&spwizard: pai flow logic for tablecontrol 'TCONTROL'
      loop at LT_VBAK.
        chain.
          field LT_VBAK-VBELN.
          field LT_VBAK-NETWR.
          field LT_VBAK-KUNNR.
          module TCONTROL_modify on chain-request.
        endchain.
        field LT_VBAK-FLAG
          module TCONTROL_mark on request.
      endloop.
      module TCONTROL_user_command.
    *&spwizard: module TCONTROL_change_tc_attr.
    *&spwizard: module TCONTROL_change_col_attr.
    MODULE USER_COMMAND_9000.
    regards
    padma

  • How to export values to a Module POOL Program

    Dear Gurus
    there is a customized infotype for an appraisal.
    i have made a program which calls that infotype module program through transaction but it shows the error that no entry in table t589a for P.
    can you guide me how to solve this issue..
    i just want to call the screen of that infotype which is seen in PA30.
    Regards Saad. Nisar.
    DATA: itab_empdata LIKE TABLE OF person.
    DATA: itab_data LIKE TABLE OF person WITH HEADER LINE.
    data: itab_info like table of pskey with HEADER LINE.
    DATA:  ppernr TYPE pa0001-pernr.
    DATA opt TYPE ctu_params.
    opt-DISMODE = 'e'.
    opt-defsize = 'X'.
    opt-updmode = 'x'.
    *----------------------Start of Selection Screen----------------------*
    SELECTION-SCREEN BEGIN OF SCREEN 100 AS SUBSCREEN.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-002 FOR FIELD pernr.
    PARAMETERS pernr TYPE pa0001-pernr.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-008 FOR FIELD ename.
    PARAMETERS ename TYPE pa0001-ename.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-003 FOR FIELD persg.
    PARAMETERS persg TYPE pa0001-persg.
    SELECTION-SCREEN COMMENT 20(15) text-009 FOR FIELD werks.
    PARAMETERS werks TYPE pa0001-werks.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-004 FOR FIELD persk.
    PARAMETERS persk TYPE pa0001-persk.
    SELECTION-SCREEN COMMENT 20(15) text-005 FOR FIELD kostl.
    PARAMETERS kostl TYPE pa0001-kostl.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-006 FOR FIELD orgeh.
    PARAMETERS orgeh TYPE pa0001-orgeh.
    PARAMETERS orgehtxt TYPE person-orgeh_txt .
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (15) text-007 FOR FIELD plans.
    PARAMETERS plans TYPE pa0001-plans.
    PARAMETERS planstxt TYPE person-plans_txt .
    SELECTION-SCREEN END OF LINE.
    "SELECTION-SCREEN END OF BLOCK b1.
    SELECTION-SCREEN END OF SCREEN 100.
    SELECTION-SCREEN: BEGIN OF TABBED BLOCK b2 FOR 6 LINES,
                      TAB (16) title USER-COMMAND '' DEFAULT SCREEN 100,
                      END OF BLOCK b2.
    SELECTION-SCREEN BEGIN OF BLOCK block WITH FRAME TITLE text-001.
    PARAMETERS intype TYPE pskey-infty.
    SELECTION-SCREEN END OF BLOCK block.
    INITIALIZATION.
      title = 'Employee Details'.
    START-OF-SELECTION.
    *AT SELECTION-SCREEN OUTPUT.
    AT SELECTION-SCREEN OUTPUT .
      LOOP AT SCREEN.
        IF screen-name = 'ENAME'
        OR screen-name = 'PERSG'
        OR screen-name = 'PERSK'
        OR screen-name = 'KOSTL'
        OR screen-name = 'WERKS'
        OR screen-name = 'ORGEH'
        OR screen-name = 'PLANS'
        OR screen-name = 'ORGEHTXT'
        OR screen-name = 'PLANSTXT'.
          screen-input = '0'.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
      LOOP AT SCREEN.
        IF screen-name = 'ORGEHTXT'
         OR screen-name = 'PLANSTXT'.
          screen-output = '1'.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
    *AT SELECTION-SCREEN .
    AT SELECTION-SCREEN .
      ppernr = pernr.
      CALL FUNCTION 'HR_GET_EMPLOYEE_DATA'
        EXPORTING
          person_id             = ppernr
          selection_begin       = sy-datum
          selection_end         = sy-datum
        IMPORTING
          personal_data         = itab_data
        EXCEPTIONS
          person_not_found      = 1
          no_active_integration = 2
          OTHERS                = 3.
    ename = itab_data-ename.
      persg = itab_data-persg.
      persk = itab_data-persk.
      orgeh = itab_data-orgeh.
      plans = itab_data-plans.
      kostl = itab_data-kostl.
      werks = itab_data-werks.
      orgehtxt = itab_data-orgeh_txt.
      planstxt = itab_data-plans_txt.
    IF pernr IS INITIAL.
        MESSAGE  'PLease Enter Employee Number' TYPE 'I'.
        " ELSEIF intype IS INITIAL.
        " MESSAGE  'PLease Appraisal Infotype' TYPE 'I'.
        "ELSE.
        "  EXIT.
      ENDIF.
      IF intype EQ 9112.
         CALL TRANSACTION 'Z9112' USING itab_info OPTIONS FROM opt.
    ENDIF.
    Moderator message - Please read Please Read before Posting in the Performance and Tuning Forum before posting - post locked
    Edited by: Rob Burbank on May 4, 2009 9:19 AM

    check this standard  program,,,
    demo_data_ext_cluster_export
    demo_data_ext_cluster_import
    This will help u
    Regards
    Anbu B

  • *How can we use the internal table in module pool programming? Clarify plz*

    If we creating a screen using the table having four fields(for e.g.). The screen has the functions of display, modify, delete, save, exit etc for the fields. The front-end of the screen having I/O fields of the table using internal table. How can we declare the internal table in the screen?

    HI,
    Create one WA for your Internal table and then map it to your fields.
    For Example,
    Data : begin of wa,
              name(10),
              age type i,
               end of wa.
    data : it like table of wa with header line.
    Then in screen create input fields with the name, age and ***.
    Then the user entered values are stored in name age and ***.
    then you can manipulate with that values using wa.
    Thanks.

  • How to call table control in subscreen in module pool program

    Hi all,
    I have req,need call table control in subscreen,but have done but when scroll bar value getting changed ,
    please guide how to do it.if its possable send the code.
    regards
    santosh

    Hi,
    The navigation happens like this.
    Consider you have a main screen and 2 subscreens.
    When you click or do some event in the Subscreen 2 (lets say this is the one that has the table control), this will first trigger PAI of the Main Screen. In the flow logic of the Main screen, you would have written call subscreen <subscreen area1> and call subscreen <subscreen area2>.
    Now the subscreens get triggered based on the order in which you have written in the flow logic.
    So, here the modules before the first call subscreen statement in the Main Screen PAI is all executed. Now, it goes to the subscreen on which you have triggered an event and executes the modules in the subscreen.
    This is how the execution goes when you have subscreens.
    So there is no problem with the navigation. You only have to worry about the screen where you have the table control. Just debug and find where data is getting changed or duplicated.

  • How to call a text editor from a module pool program

    Hi All,
    I want to call the text editor from my modulepool program. Enter my text in it and save it.This text needs to be saved in a Z-program with 2 fields as primary keys. The next time while I call this same record from this z table, I need to fetch the existing text and display it.
    The user now can put in additional text and can again save it. This process thus goes on..
    If anyone has worked in this type of scenario, then please help me in doing this.
    Useful answers will surely be rewarded.
    Thanks,
    Susanth.

    Hi Sushanth,
    We save the text not as fields in a ztable directly but as a text.Please check the format below since it is based on a working code....
    first you need to create a text in s010 transaction...
    there should be some key based on which you plan to save the text..imagine it is Purchase order then..PO+item numner is always unique.eg:0090010(900PO/item10).so in the code you can append these two and they will be unique..so you can always retrieve them,overwrite,save them anytime you need
    **************data declarations
    TYPES: BEGIN OF TY_EDITOR,
    EDIT(254) TYPE C,
    END OF TY_EDITOR.
    data: int_line type table of tline with header line.
    data: gw_thead like thead.
    data: int_table type standard table of ty_editor.
    ****************fill header..from SO10 t-code..when you save you need the unique key..youfill it here and pass it in save_text function module
    GW_THEAD-TDNAME = loc_nam. " unique key for the text -> our unique key to identify the text
    GW_THEAD-TDID = 'ST'. " Text ID from SO10
    GW_THEAD-TDSPRAS = SY-LANGU. "current language
    GW_THEAD-TDOBJECT = 'ZXXX'. "name of the text object created in SO10
    *To Read from Container and get data to int_table
    CALL METHOD EDITOR ->GET_TEXT_AS_R3TABLE
    IMPORTING
    TABLE = int_table
    EXCEPTIONS
    ERROR_DP = 1
    ERROR_CNTL_CALL_METHOD = 2
    ERROR_DP_CREATE = 3
    POTENTIAL_DATA_LOSS = 4
    others = 5.
    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 data from int_table and save to int_line-tdline appending it.
    *save the text
    CALL FUNCTION 'SAVE_TEXT'
    EXPORTING
    HEADER = GW_THEAD
    TABLES
    LINES = InT_LINE
    EXCEPTIONS
    ID = 1
    LANGUAGE = 2
    NAME = 3
    OBJECT = 4
    OTHERS = 5.
    IF SY-SUBRC 0.
    ENDIF.
    *To pass to Container
    CALL METHOD EDITOR ->SET_TEXT
    hope that the above sample with helps you solve the problem
    Please check and revert,
    Reward if helpful
    Regards
    Byju

  • How to add ALV button using OO in module pool program using ALV grid

    Hello Gurus!!!
                  Want some tips related how to add button using ALV Grid(OO).
    I want to display the button for search, sort ....
                 Please suggest the step -by-step procedure for implementation of these button.
                 I am designing the code for transaction FB03. Header data has been displayed but want to display the line items.
                 Kindly suggest your answers.
    Thanks,
    Sachin

    Hi,
    CLASS SELSCR_APPLICATION DEFINITION DEFERRED.
    CLASS SELSCR_APPLICATION DEFINITION.
      PUBLIC SECTION.
       METHODS:
            HANDLE_TOOLBAR
            FOR EVENT TOOLBAR OF CL_GUI_ALV_GRID
                IMPORTING E_OBJECT  E_INTERACTIVE,
            HANDLE_USER_COMMAND
            FOR EVENT USER_COMMAND OF CL_GUI_ALV_GRID
                IMPORTING E_UCOMM.
    ENDCLASS.        "SELSCR_APPLICATION DEFINITION
    CLASS SELSCR_APPLICATION IMPLEMENTATION.
      METHOD HANDLE_TOOLBAR.
        DATA: LS_TOOLBAR  TYPE STB_BUTTON.
    append SAVE icon
        CLEAR LS_TOOLBAR.
        MOVE 'SAVE' TO LS_TOOLBAR-FUNCTION.
        MOVE ICON_SYSTEM_SAVE TO LS_TOOLBAR-ICON.
        MOVE 'Save' TO LS_TOOLBAR-QUICKINFO.
        MOVE ' '  TO LS_TOOLBAR-DISABLED.
        APPEND LS_TOOLBAR TO E_OBJECT->MT_TOOLBAR.
        CLEAR LS_TOOLBAR.
      ENDMETHOD.                    "handle_toolbar
      METHOD HANDLE_USER_COMMAND.
        CASE E_UCOMM.
          WHEN 'SAVE'.
              PERFORM UPDATE_FIELDS.
        ENDCASE.
      ENDMETHOD.
    ENDCLASS.                 "SELSCR_APPLICATION IMPLEMENTATION
    these lines should be after calling method SET_TABLE_FOR_FIRST_DISPLAY
    SET HANDLER G_APPLICATION1->HANDLE_TOOLBAR FOR GRID1.
            CALL METHOD grid1->set_toolbar_interactive.
    rgds,
    bharat.

  • SCREEN field values

    Dear Sir,
            Can any body pls tell me how to pass screen field values generically in dialogue programming...the screen field values like input,output, group...
    Can we use the table 'SCREEN' in dialogue programming..?? & how???
    Regards,
    Rushikesh

    Hi Rushikesh,
    What exactly is your requirement....?
    You can use the table SCREEN for modifying the screen element attributes at runtime...
    Suppose for example , when I click on a button, I want a button to be displayed...It can be done , but only in the PBO event....
    Initially , go to the screen attributes and make it invisible...
    Now in the program, you can do like this
    1) Declare a global variable (say flag initialized to zero).
    2) In PBO event
    LOOP AT SCREEN.
    IF SCREEN-NAME = 'FIELD1' and FLAG = 1.
    screen-invisible = 0.
    modify screen.
    endif.
    endloop.
    3) In PAI event.
    case sy-ucomm.
    when 'CLICK'.
    flag = 1.
    endcase.
    This is one example , you can have any number of situations.
    Regards,
    SP.

  • 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.

Maybe you are looking for

  • AIO Remote not working

    We have an HP 6500 E710n which has worked flawlessly with the AIO Remote IOS app since it was introduced.  The app was updated in the last few weeks and it is now not scanning remotely.  The app will communicate to the printer, intitiate the document

  • How do I unblock names in FaceTime app?

    how do I unblock people in Facetime?

  • Problem w/ headphones

    I have a problem using my new headphones with my 5g iPod. Every time the headphones are adjusted slightly in the headphone jack, the iPod thinks the headphones are disconnected and pauses whatever's playing. The problem has gotten worse since I updat

  • Saving panoramic with photomerge Elements 9

    after saving my panoramic the file format is not compatible with Lightroom or any other photosoftware, please help!!!

  • Little bug in Access Connections [fixed]

    Today I have reinstalled my OS (with drivers and applications) twice because of problems with WiFi application (famous Fn+F5)... but I'm too tired of this to describing it tonight What I want to say is that I have noticed small bug (?) in Access Conn