No Ok_Code for scrolling in table control

Hi,
  I m using Tcode FPP1 (PSCD module) for creating business
  partners while creating the industry type I have a table
  control where I need to entre values but when values are
  getting exceeded the table control does not scroll in batch
  input mode nor while recording it gave any kind of Ok_code
  for this.
How do I now scroll I have tries '=P+' and '=PAUA_T' but it does not work can some one help on this.
Thanks,
Vaibhav B Gawali.

You can try and put a Loop within your perform statements,at  poin where you need to do this scrolling.
you can take help of a counter variable to keep track of you record and perfor m the scrolling operation.
Say the screen can take 6 record at a time. you can initialise the couter CNT with value 1 and loop in this statement till the counter reaches 7. Once the counter reaches 7,you can perform BDC_CODE = 'P+' and reset the counter to 1 again.
This is just a logic,you can implement it as per you code.
Thanks n Regs,
Bhavin

Similar Messages

  • How to manage scrolling in Table Control

    Hi,
    I have one scenario in which i have one table control in that one column contains check boxes. After i check, some check boxes in  some rows and press scrolling button means the selection previously made goes off. I want the selection remains selected.
    Please any one suggest me how to manage this.
    Regards,
    Mithun.

    Your PAI flow logic should be following this type of structure:
    process after input.
      module at_exit_command at exit-command. "don't exit here if you want TC data changes
      module d9999_before_tc.
      loop with control tc_9999.
        chain.
          field:
            gs_9999_tc-sel,
            gs_9999_tc-checkbox.
          module d9999_line_tc_handler.  "hold onto TC row data in here
        endchain.
      endloop.
      module d9999_user_command. 
      module d9999_pai_scroll.  "scroll the table control
    As noted above, you need to catch the values of your checkboxes within the loop / endloop for the table control, and do any scrolling after this.
    Jonathan

  • How to control manually the scrolling of Table Control?

    Hi,
    I have one selection screen which takes me to the next screen (Screen 2) having a table control.In this screen I have some buttons like display, change etc ,by clicking on which it goes to the third screen.Now my problem is even when I try to vertically scroll this table control it is taking me to the third screen which I do not want to happen. Could anyone please help me in this.
    Thanks in advance.

    In PBO write the following code for scrolling
    *& Module set_lines OUTPUT
    text
    MODULE SET_LINES OUTPUT.
    DATA VLINES TYPE I.
    DESCRIBE TABLE ITABCTL LINES VLINES.
    TABCTL-LINES = VLINES + 1.
    ENDMODULE. " set_lines OUTPUT
    This is code for vertical scrollin..
    Howevr check ur ok-codes..
    Hope dis helps...
    reward if it does..

  • BDC Recording For J1IG with Table Control Scroll bar

    Dear Friends,
    I am doing BDC program for J1IG Transaction after done recording.
    As you knows that, In J1IG transaction max. 11 materials are shows in table control at a time and if more records are there, then we have to scroll down manually so after that, we can see the records.
    Now my BDC program runs upto 11 materials but when more than 11 materials, selection is coming on first material only and cursor not showing 12th material.
    So i think page down is not working for that issue.
    I have seen lots of search forum for that but not getting the proper answer.
    Please reply.
    Regards,
    Shivam.

    Dear Dinu,
    For better understanding please see the code.
    So you suggest what should i have to do?.
    LOOP AT jtab INTO wb.
         LOOP AT itab INTO wa WHERE mblnr EQ wb-mblnr.
           CLEAR : flag.
           AT NEW mblnr.
             flag = 'X'.
             CLEAR : cnt, var1, var2.
           ENDAT.
           cnt = cnt + 1.
           IF flag EQ 'X'.
             PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0100'.
             PERFORM bdc_field       USING 'BDC_OKCODE'
                                       '=ECAP'.
             PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0200'.
             PERFORM bdc_field       USING 'BDC_CURSOR'
                                       'T_HEADER-EXDAT'.
             PERFORM bdc_field       USING 'BDC_OKCODE'
                                       '/00'.
             PERFORM bdc_field       USING 'J_1IEXCHDR-EXGRP'
                                       wa-exgrp.
             PERFORM bdc_field       USING 'T_HEADER-MBLNR'
                                       wa-mblnr.
             PERFORM bdc_field       USING 'T_HEADER-MJAHR'
                                       wa-mjahr.
             PERFORM bdc_field       USING 'T_HEADER-EXNUM'
                                       wa-exnum.
             PERFORM bdc_field       USING 'T_HEADER-EXDAT'
                                       wa-exdat.
             PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0200'.
             PERFORM bdc_field       USING 'BDC_CURSOR'
                                       'J_1IEXCHDR-EXGRP'.
             PERFORM bdc_field       USING 'BDC_OKCODE'
                                       '=DETL'.
           ENDIF.
           CONCATENATE 'T_ITEM-ZEILE(' cnt ')'  INTO var1.
           CONCATENATE 'T_ITEM-SELECTION(' cnt ')'  INTO var2.
           PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0300'.
           PERFORM bdc_field       USING 'BDC_CURSOR'
                                     var1.           "'T_ITEM-ZEILE(01)'.
           PERFORM bdc_field       USING 'BDC_OKCODE'
                                     '=MORE'.
           PERFORM bdc_field       USING var2 "'T_ITEM-SELECTION(01)'
                                     'X'. "record-selection_01_019.
           PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0400'.
           PERFORM bdc_field       USING 'BDC_CURSOR'
                                    'T_LOCAL_EXC-EXADDRATE1(01)'.
           PERFORM bdc_field       USING 'BDC_OKCODE'
                                     '/00'.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-MENGE(01)'
                                     wa-menge.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-EXBAS(01)'
                                     wa-exbas.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-EXBED(01)'
                                     wa-exbed.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-BEDRATE(01)'
                                     wa-bedrate.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-EXAED(01)'
                                     wa-exaed.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-AEDRATE(01)'
                                     wa-aedrate.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-ECS(01)'
                                     wa-ecs.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-ECSRATE(01)'
                                     wa-ecsrate.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-EXADDTAX1(01)'
                                     wa-exaddtax1.
           PERFORM bdc_field       USING 'T_LOCAL_EXC-EXADDRATE1(01)'
                                     wa-exaddrate1.
           PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0400'.
           PERFORM bdc_field       USING 'BDC_CURSOR'
                                     'T_LOCAL_EXC-RG23ASER(01)'.
           PERFORM bdc_field       USING 'BDC_OKCODE'
                                     '=BACK'.
         ENDLOOP.
         PERFORM bdc_dynpro      USING 'SAPMJ1IG' '0300'.
         PERFORM bdc_field       USING 'BDC_CURSOR'
                                   'T_ITEM-DOCNO(01)'.
         PERFORM bdc_field       USING 'BDC_OKCODE'
                                   '=SAVE'.
         CLEAR opt.
         opt-dismode = 'A'.
         opt-updmode = 'S'.
    *    opt-defsize = '12'.
    *    CLEAR: it_messages[], it_messages.
         CALL TRANSACTION 'J1IG' USING it_bdcdata OPTIONS FROM opt
                                       MESSAGES INTO it_messages.
         REFRESH it_bdcdata.
       ENDLOOP.
       CHECK it_messages[] IS NOT INITIAL.
       LOOP AT it_messages.
         PERFORM fill_messages USING it_messages-msgtyp
                                     it_messages-msgid
                                     it_messages-msgnr
                                     it_messages-msgv1
                                     it_messages-msgv2
                                     it_messages-msgv3
                                     it_messages-msgv4.
       ENDLOOP.
       PERFORM display_messages TABLES tmsg.

  • Problem in SCROLLING  of TABLE CONTROL which is designed using WIZARD

    Hello Friends ,
                              I have designed a entry screen by using table control with wizard.  My table control layout  has 11 rows. I have used all 3 facilities i.e. SCROLLING , INSERT/DELETE  & SELECT/DESELECT by cheking ( ticking ) check boxes while designing table control with wizard.  
      Now i have 3 problems.
    1> In my entry screen , if 11 entries are entered , they are displayed in entry screen and are saved correctly in DB.
         But when  i copy a file of suppose 15 entries into entry screen then it displays only 11 entries in entry screen and after that  if  i click/move  VERTICAL SCROLL BAR to see remaining/next 4 entries  then it does not display  12th 13th 14th &15th entry in entry screen. So the problem is i am unable to display remaining/next 4 entries  in entry screen & also to save them DB.
    2>  At the same time when i click/move  VERTICAL SCROLL BAR to see remaining/next 4 entries  then  earlier 11 entries  are disappeared/ get cleared from entry screen.
    3> The FIRST PAGE, PREVIOUS PAGE , NEXT PAGE , LAST PAGE and INSERT , DELETE push buttons are dispalyed in my entry screen . But they are not working or doing their opertions on table control though there is system generated code for them written in module pool program and  PBO & PAI OF SCREEN 100 on which table control is present.
       So eagerly waiting for POSITIVE replies  &  Correct solutions from all ABAP techies.
    THANKS & REGARDS,
      Ashish.

    Hi friend,
                         I have visited the link u have given . But it is a report program .it is available in ABAPDOCU tcode.
    ABAPDOCU----
    >ABAP User Dialogs -
    >Screens -
    >Complex Screen Elements -
    >Table Control with Scrolling .
    It is a REPORT program. and not a module pool program. plz check this in ur link also.
    REPORT demo_dynpro_tabcont_loop.    &
    *SELECT * FROM spfli INTO CORRESPONDING FIELDS OF TABLE itab.* -
    > this statement is used only in report program and system does not allow us to use in module pool program.
    Second thing here data is retrived from spfli table where as my data will be whatever enduser enters it may be 15 lines , may be 50 lines or may be 200 lines and it shold be displayed on entry screen before clicking SAVE or any other user action.
    My main problem is that I am unable to enter more than 11 entries in my entry screen. I want dynaamic table. Mean whichever enteries are entered they should be displayed on entry screen as well as can be scrolled up & down before saving and get saved after clicking SAVE button. here table control design is not imp because entry data depends on table control layout rows & which has limit. It can not be extended beyond certain level. i think max will be 20 Or 25 rows in layout. How to make it dynamic so that we can get any no. of entries in entry screen hiich canbe scrolled up & down.
    Anyways thanks for ur reply And send some other soln.
    Thanks & regards,
    Ashish

  • Error in Vertical Scrolling of Table Control

    Hi All,
    I make Table control using wizard for internal table which I declare in TOP include.
    But my Vertical Scrolling is not working.
    Would appreciate your reply .
    Regards,
    Pooja

    Hi pooja ,
    When you will fill the entries till the bottom  , scroll will appear .
    don't worry about it
    Regards
    Yogendra Bhaskar

  • Vertical scrolling in table control

    Hi Friends,
    How to enable the vertical scroll bar in the table control.  I my form, this is not working, but horizontal scroll bar is working.
    Kindly guide me to get the vertical scroll bar working.
    TIA.
    Regards,
    Mark K

    Hi,
    Let us say table control name is TC1. You have to assign a value to TC1-lines in PBO event in a module.
    try this. Determine the number of records in your internal table.
    describe table itab lines gv_lines.
    TC1-lines = gv_lines.
    thanks,
    sksingh

  • Different user settings for scrolling in tables or ALVs

    Hi Experts,
    I have a strange problem.
    I have a Web Dynpro Application that uses the UI Element table. For one user who uses it the scrolling mode is a scrollbar and for an other user the scrolling mode is a paginator. That appears not only for this application. ALL applications on the system have this difference for users. So, not only in tables does that appear. In ALVs too!
    Does anybody know where I can configure this for every single user?
    Thanks a lot!
    Best regards,
    Ingmar

    The only thing I can figure is that the user getting the paginartor has accessibility turned on:
    http://help.sap.com/saphelp_nw70ehp1/helpdata/en/19/e64941bfb4de2be10000000a1550b0/frameset.htm
    That is the only option I know of that should override the system or application settings for scrolling.  In particular accessibility can be turned on at the user profile level:
    To do this, in transaction SU01 for your user name choose the tabstrip Parameters, insert the parameter ID ACCESSIBILITY_MODE with the value X, and save the entry.
    Or within the portal:
    To do this, in your user profile in the portal, under General Information select option Activate Accessibility (Screen Reader Required) and save your entries. This specification is evaluated by Web Dynpro ABAP.

  • Code for va01 bdc table control

    hi
    i want to CODE FOR  bdc table control  VA01 (TCODE)
    ASAP

    Awadhesh,
    just refer:
    Problem in the BDC Table Control for the T.Code VA01
    BDC Uploading from flat file to VA01.
    BDC For Line Items In Sales Order
    dont forget reward.
    Amit.

  • Module pool program - populating values for columns in Table control

    Hi all,
    In my module pool program Table control i  am having 10 columns fields.
    in one of the column field i have used 'PROCESS ON VALUE-REQUEST'   to get the material no.
    in that F4 search help list is having releated information of the material like material group, company code, description etc.
    user while searching for material  they will use F4 search help and in that list they will select the material .
    From the list I need releated information of the materials like material group, company code, description etc
    to be populated in other columns while selecting the material .( User is not ready to enter all the values for the fileds)
    I appended the releated values for the material in the Table control Internal table in the Process on value-request  Module.
    (after selecting material by the user from F4 search help)
    even then I am not getting the data in the screen.
    kindly help me how to proceed  to get the data in other columns.
    Thanks in advance,
    sharma

    Hi Himanshu Verma ,
    Thanks for fast reply.
    but i tried with field names available in F4  Internal table.
    even then I am not getting.
    T_DYNPFLD_MAPPING-FLDNAME = ' MTART.
    APPEND T_DYNPFLD_MAPPING TO ITAB_DYNPFLD_MAPPING.
    T_DYNPFLD_MAPPING-FLDNAME = 'MBRSH'.
    APPEND T_DYNPFLD_MAPPING TO ITAB_DYNPFLD_MAPPING.
      SELECT
      MATNR
    MTART
    MBRSH
    MATKL
    BISMT
    MEINS
    BSTME
      FROM MARA
      INTO TABLE INT_F4
      up to 5000 rows
      CLEAR INT_F4.
    ****function module to get pop-up window of f4.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          RETFIELD        = 'MATNR'
          DYNPPROG        = W_PROGNAME
          DYNPNR          = W_SCR_NUM
          DYNPROFIELD     = 'V_TAB-MATNR'
          VALUE_ORG       = 'S'
        TABLES
          VALUE_TAB       = INT_F4
          RETURN_TAB      = RETURN_VALUES
          DYNPFLD_MAPPING = ITAB_DYNPFLD_MAPPING
        EXCEPTIONS
          PARAMETER_ERROR = 1
          NO_VALUES_FOUND = 2
          OTHERS          = 3.
      IF SY-SUBRC NE 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ELSE .
        V_TAB-matnr = RETURN_VALUES-FIELDVAL.
    endif.
    I have used the above code.  I am not getting the field values available in ITAB_DYNPFLD_MAPPING.
    kindly help me how to get the exact row for the F4 table.
    Thanks in advance.
    sharma

  • Problem with Vertical scroll in table control

    Dear All,
    I am facing a problem with table control in module pool program. currently it displays 6 lines, but it does not display the vertical scroll button, even though when I fill data in the six rows and hit enter.
    I have set the vertical scroll option on the table control properties also.
    Can someone help me by sending some sample code?
    Thanks,
    Amit Goyal

    HI Amit ,
        If you have already selected the properties of vertical and horizontal scroll bar then no other operations needed .. if the number of rows increases then that of the table control , you will automatically see the Vertical scroll in your table control ..
      if still you dont see it then write back ..
    Reward if helpful !
    Thanks
    Ranjita

  • How can we get a Scrolling in Table Control while data uploading?.

    Can anybody suggest me the way to put a scrolling in a table control while uploading the data?

    Hello,
    I dont think it is possible, anyways dont do it. It will make the program perfomance very bad. There is an indicator (little watch on the left hand side), that you can use, but it is better to dont do it. As I have told you the perfomance will be very bad.
    CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
        EXPORTING
          percentage = 20
          text       = 'Uploading data'.
    THAT IS THE FM. Use it after and before the upload.
    Hope this helps
    Gabriel

  • BDC program for rebate with table controls

    Hi Friends,
    Iam Doing  bdc program for Rebate(TCODE VBO1) with table controls..
    can u give the solutions for table controls...
    if anybody having the code..please send me..
    Thanks & Advance,
    sampath

    hi,
    check this example it may help you.
    REPORT  ZSR_BDC_TBCTRL
            NO STANDARD PAGE HEADING LINE-SIZE 255.
    TABLES : RF02K,LFA1,LFBK.
    DATA : BEGIN OF IT_VEN OCCURS 0,
          LIFNR LIKE RF02K-LIFNR,
          KTOKK LIKE RF02K-KTOKK,
          NAME1 LIKE LFA1-NAME1,
          SORTL LIKE LFA1-SORTL,
          LAND1 LIKE LFA1-LAND1,
          SPRAS LIKE LFA1-SPRAS,
          BANKS(6) TYPE C,
          BANKL(17) TYPE C,
          BANKN(19) TYPE C,
          END OF IT_VEN.
    DATA : BEGIN OF BANKS OCCURS 0,
           BANKS LIKE LFBK-BANKS,
           END OF BANKS,
           BEGIN OF BANKL OCCURS 0,
           BANKL LIKE LFBK-BANKL,
           END OF BANKL,
           BEGIN OF BANKN OCCURS 0,
           BANKN LIKE LFBK-BANKN,
           END OF BANKN.
    DATA : FLD(20) TYPE C,
           CNT(2) TYPE N.
    DATA : BDCTAB LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
    INCLUDE BDCRECX1.
    START-OF-SELECTION.
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      = 'Z:\sr.TXT'
       FILETYPE                      = 'ASC'
       HAS_FIELD_SEPARATOR           = 'X'
      HEADER_LENGTH                 = 0
      READ_BY_LINE                  = 'X'
      DAT_MODE                      = ' '
      CODEPAGE                      = ' '
      IGNORE_CERR                   = ABAP_TRUE
      REPLACEMENT                   = '#'
      CHECK_BOM                     = ' '
    IMPORTING
      FILELENGTH                    =
      HEADER                        =
      TABLES
        DATA_TAB                      = IT_VEN
    EXCEPTIONS
      FILE_OPEN_ERROR               = 1
      FILE_READ_ERROR               = 2
      NO_BATCH                      = 3
      GUI_REFUSE_FILETRANSFER       = 4
      INVALID_TYPE                  = 5
      NO_AUTHORITY                  = 6
      UNKNOWN_ERROR                 = 7
      BAD_DATA_FORMAT               = 8
      HEADER_NOT_ALLOWED            = 9
      SEPARATOR_NOT_ALLOWED         = 10
      HEADER_TOO_LONG               = 11
      UNKNOWN_DP_ERROR              = 12
      ACCESS_DENIED                 = 13
      DP_OUT_OF_MEMORY              = 14
      DISK_FULL                     = 15
      DP_TIMEOUT                    = 16
      OTHERS                        = 17
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    PERFORM OPEN_GROUP.
    LOOP AT IT_VEN.
        REFRESH BDCDATA.
        REFRESH : BANKS,BANKL,BANKN..
        SPLIT IT_VEN-BANKS AT ',' INTO TABLE BANKS.
        SPLIT IT_VEN-BANKL AT ',' INTO TABLE BANKL.
        SPLIT IT_VEN-BANKN AT ',' INTO TABLE BANKN.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0100'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'RF02K-KTOKK'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_FIELD       USING 'RF02K-LIFNR'
                                  IT_VEN-LIFNR.
    PERFORM BDC_FIELD       USING 'RF02K-KTOKK'
                                  IT_VEN-KTOKK.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0110'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFA1-SPRAS'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_FIELD       USING 'LFA1-NAME1'
                                  IT_VEN-NAME1.
    PERFORM BDC_FIELD       USING 'LFA1-SORTL'
                                  IT_VEN-SORTL.
    PERFORM BDC_FIELD       USING 'LFA1-LAND1'
                                  IT_VEN-LAND1.
    PERFORM BDC_FIELD       USING 'LFA1-SPRAS'
                                  IT_VEN-SPRAS.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0120'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFA1-KUNNR'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0130'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFBK-BANKN(02)'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=ENTR'.
    *perform bdc_field       using 'LFBK-BANKS(01)'
                                 'DE'.
    *perform bdc_field       using 'LFBK-BANKS(02)'
                                 'DE'.
    *perform bdc_field       using 'LFBK-BANKL(01)'
                                 '10020030'.
    *perform bdc_field       using 'LFBK-BANKL(02)'
                                 '67270003'.
    *perform bdc_field       using 'LFBK-BANKN(01)'
                                 '12345'.
    *perform bdc_field       using 'LFBK-BANKN(02)'
                                 '66666'.
    MOVE 1 TO CNT.
        LOOP AT BANKS.
          CONCATENATE 'LFBK-BANKS(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKS-BANKS.
          CNT = CNT + 1.
        ENDLOOP.
        MOVE 1 TO CNT.
        LOOP AT BANKL.
          CONCATENATE 'LFBK-BANKL(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKL-BANKL.
          CNT = CNT + 1.
        ENDLOOP.
        MOVE 1 TO CNT.
        LOOP AT BANKN.
          CONCATENATE 'LFBK-BANKN(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKN-BANKN.
          CNT = CNT + 1.
        ENDLOOP.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0130'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFBK-BANKS(01)'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=ENTR'.
    PERFORM BDC_DYNPRO      USING 'SAPLSPO1' '0300'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=YES'.
    PERFORM BDC_TRANSACTION USING 'XK01'.
    ENDLOOP.
    PERFORM CLOSE_GROUP.&----
    *& Report  ZSR_BDC_TBCTRL
    REPORT  ZSR_BDC_TBCTRL
            NO STANDARD PAGE HEADING LINE-SIZE 255.
    TABLES : RF02K,LFA1,LFBK.
    DATA : BEGIN OF IT_VEN OCCURS 0,
          LIFNR LIKE RF02K-LIFNR,
          KTOKK LIKE RF02K-KTOKK,
          NAME1 LIKE LFA1-NAME1,
          SORTL LIKE LFA1-SORTL,
          LAND1 LIKE LFA1-LAND1,
          SPRAS LIKE LFA1-SPRAS,
          BANKS(6) TYPE C,
          BANKL(17) TYPE C,
          BANKN(19) TYPE C,
          END OF IT_VEN.
    DATA : BEGIN OF BANKS OCCURS 0,
           BANKS LIKE LFBK-BANKS,
           END OF BANKS,
           BEGIN OF BANKL OCCURS 0,
           BANKL LIKE LFBK-BANKL,
           END OF BANKL,
           BEGIN OF BANKN OCCURS 0,
           BANKN LIKE LFBK-BANKN,
           END OF BANKN.
    DATA : FLD(20) TYPE C,
           CNT(2) TYPE N.
    DATA : BDCTAB LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
    INCLUDE BDCRECX1.
    START-OF-SELECTION.
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      = 'Z:\sr.TXT'
       FILETYPE                      = 'ASC'
       HAS_FIELD_SEPARATOR           = 'X'
      HEADER_LENGTH                 = 0
      READ_BY_LINE                  = 'X'
      DAT_MODE                      = ' '
      CODEPAGE                      = ' '
      IGNORE_CERR                   = ABAP_TRUE
      REPLACEMENT                   = '#'
      CHECK_BOM                     = ' '
    IMPORTING
      FILELENGTH                    =
      HEADER                        =
      TABLES
        DATA_TAB                      = IT_VEN
    EXCEPTIONS
      FILE_OPEN_ERROR               = 1
      FILE_READ_ERROR               = 2
      NO_BATCH                      = 3
      GUI_REFUSE_FILETRANSFER       = 4
      INVALID_TYPE                  = 5
      NO_AUTHORITY                  = 6
      UNKNOWN_ERROR                 = 7
      BAD_DATA_FORMAT               = 8
      HEADER_NOT_ALLOWED            = 9
      SEPARATOR_NOT_ALLOWED         = 10
      HEADER_TOO_LONG               = 11
      UNKNOWN_DP_ERROR              = 12
      ACCESS_DENIED                 = 13
      DP_OUT_OF_MEMORY              = 14
      DISK_FULL                     = 15
      DP_TIMEOUT                    = 16
      OTHERS                        = 17
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    PERFORM OPEN_GROUP.
    LOOP AT IT_VEN.
        REFRESH BDCDATA.
        REFRESH : BANKS,BANKL,BANKN..
        SPLIT IT_VEN-BANKS AT ',' INTO TABLE BANKS.
        SPLIT IT_VEN-BANKL AT ',' INTO TABLE BANKL.
        SPLIT IT_VEN-BANKN AT ',' INTO TABLE BANKN.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0100'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'RF02K-KTOKK'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_FIELD       USING 'RF02K-LIFNR'
                                  IT_VEN-LIFNR.
    PERFORM BDC_FIELD       USING 'RF02K-KTOKK'
                                  IT_VEN-KTOKK.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0110'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFA1-SPRAS'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_FIELD       USING 'LFA1-NAME1'
                                  IT_VEN-NAME1.
    PERFORM BDC_FIELD       USING 'LFA1-SORTL'
                                  IT_VEN-SORTL.
    PERFORM BDC_FIELD       USING 'LFA1-LAND1'
                                  IT_VEN-LAND1.
    PERFORM BDC_FIELD       USING 'LFA1-SPRAS'
                                  IT_VEN-SPRAS.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0120'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFA1-KUNNR'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '/00'.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0130'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFBK-BANKN(02)'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=ENTR'.
    *perform bdc_field       using 'LFBK-BANKS(01)'
                                 'DE'.
    *perform bdc_field       using 'LFBK-BANKS(02)'
                                 'DE'.
    *perform bdc_field       using 'LFBK-BANKL(01)'
                                 '10020030'.
    *perform bdc_field       using 'LFBK-BANKL(02)'
                                 '67270003'.
    *perform bdc_field       using 'LFBK-BANKN(01)'
                                 '12345'.
    *perform bdc_field       using 'LFBK-BANKN(02)'
                                 '66666'.
    MOVE 1 TO CNT.
        LOOP AT BANKS.
          CONCATENATE 'LFBK-BANKS(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKS-BANKS.
          CNT = CNT + 1.
        ENDLOOP.
        MOVE 1 TO CNT.
        LOOP AT BANKL.
          CONCATENATE 'LFBK-BANKL(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKL-BANKL.
          CNT = CNT + 1.
        ENDLOOP.
        MOVE 1 TO CNT.
        LOOP AT BANKN.
          CONCATENATE 'LFBK-BANKN(' CNT ') ' INTO FLD.
          PERFORM BDC_FIELD USING FLD BANKN-BANKN.
          CNT = CNT + 1.
        ENDLOOP.
    PERFORM BDC_DYNPRO      USING 'SAPMF02K' '0130'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LFBK-BANKS(01)'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=ENTR'.
    PERFORM BDC_DYNPRO      USING 'SAPLSPO1' '0300'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=YES'.
    PERFORM BDC_TRANSACTION USING 'XK01'.
    ENDLOOP.
    PERFORM CLOSE_GROUP.

  • How can I get the table control up arrow or down arrow SCROLL OK_CODE?

    Dear All,
    I want get the table control up or down Scroll OK_CODE (not button, is arrow click), But I debugged have not found when I click the up or down scroll.
    Please give me some help.
    Thanks

    Hi Sun,
    PBO..
                               Loop with control T1.
                       module get_Looplines.
                    Endloop.
                        Module get_looplines.
                          Looplines = sy-loopc.      "<< by using this you can get the scroll bar...
                        Endmodule.
    if you wan the ok_code for scroll bar in table control...
    the ok_code is not generated for scroll bar..
    but if you do not clear the ok_code in PBO it will carries the ok_code when ever you press scroll bar up and down...same ok_code is repeated..
    Regards,
    Prabhudas

  • BDC_OK code for scrolling in custon table control

    Hi All,
    I have a requirement to create a BDC program for transaction ME31K, but the problem is this ME31K transaction is enhanced adding a custom screen which has three custom table controls. Now this screen is also included in the BDC program.
    I am facing problem in tracking the BDC_OKcode for scrolling for these custom table controls. Tried with '=P+' but not working.
    While recording it is capturing '/00' for scrolling but while executing through program it is not working.
    If anybody has faced this situation before please suggest how to go about it.
    Please note '=NP'  is not avaiable as it is a custom screen.
    Thanks in advance.

    go on the screen where you have table control, put /h in command field.
    now scroll in table control, this will go in debugger and now check sy-ucomm.
    hope you get it.

Maybe you are looking for