Dynamic output & input fields in the table control

HI Guys,
How can one change the attribute of  input field to output field basically greying of field) dynamically
based on the some flag. Loop at screen does not work. I need to change the attributes
of field 'outfiled' and output field display only'.
Any help is highly appreciated.
Regards,
Harsha

Hi Harsha,
I generated a table control (ERP 6.2) and somewhere I found the coding like this (the name of the table control is TABLE_CONTROL):
*&spwizard: output module for tc 'TABLE_CONTROL'. do not change this lin
*&spwizard: get lines of tablecontrol
module TABLE_CONTROL_get_lines output.
  g_TABLE_CONTROL_lines = sy-loopc.
If I do a loop at the screen at this place, I can control the individual input/output for the screen fields (the table fields). In my work area (WA_CONTROL) I can see the actual value of fields. Depending on this, I choose to enable/disable input via:
loop at screen.
if wa_control-material <> ' '.
screen-input = '0'.
modify screen.
endif.
endloop.

Similar Messages

  • Add columns with custom fields in the table control of MIGO

    Hi,
    I have to add custom fields in the table control view of item in the MIGO.  I have added the fields in the GOITEM structure and i am able to display it in the item details tab.  I want the same fields to be visible as columns in the table control view of the items.
    I found that TV_GOITEM is the control in SAPLMIGO program referring to the table control of items but it is referring only to the standard fields available in Screen 200.
    Please let me know if there is any screen exit or option to add the custom fields in the control TV_GOITEM.
    Thanks.

    Hi,
    Thanks for your reply.  I have added the custom fields in the item detail.  But the customer wants the custom fields in the table view also.
    Is there any screen exit available to modify the table control of MIGO?
    Thanks.

  • Is it possible to add icons to a field in the table control  ?

    Dear Gurus,
               Greetings..............
    Is it possible to add icons to the line item of  a field in the table control ?
    Thanks in advance
    Raj Kumar

    HI
    YES IT IS POSSIBLE.
    DO THE FOLLOWING
    1.DECLARE INCLUDE <ICON>.
    2.IN YOUR INTERNAL TABLE DECLARE FIELD ICON
    icon(4) TYPE c,
    3. POPULATE YOUR INTERNAL TABLE WITH APPROPRIATE ICONS BY SELECTING FROM INCLUDE SPECIFIED ABOVE.
    EG:
    wa2-icon = '@5C@'.
    4.PASS IT TO FIELDCAT
    wa_fieldcat-fieldname = 'ICON'.
        wa_fieldcat-icon = 'X'.            " Displayed as Icon
      wa_fieldcat-tabname = ' '.
      wa_fieldcat-seltext = 'Status'.
      wa_fieldcat-coltext = text-001.
      APPEND wa_fieldcat TO it_fieldcat.

  • ME51N update MPN Material field in the table control

    Hi Gurus,
    My requirement is to update the field MPN Material in the table control of tcode ME51N as soon as i enter the material this field should get updated.
    Please give me suggestions.
    Regards,
    Milind

    please see the link ...in this the   datefields also included in the table control  of the 
    Screen  program  ....  how the  fields are  populated in the table  using wizard ..
    <a href="http://">http://www.sapdevelopment.co.uk/dialog/tabcontrol/tc_basic.htm</a>
    reward points if it is usefull ....
    Girish

  • How to get the value from the Input field of the Table view.

    Hi Experts,
    I have created a table view with 10 rows and each rows contains input fields in it.Can you please help me getting the values that are entered in all 10 rows.
    Currently I am using the below code,but using the below I am able to get only the first row details of the table.
      lo_el_table->get_static_attributes(
        IMPORTING
          static_attributes = ls_table).
    Please let me know you suggestions on this.Thanks in advance.
    Regards,
    Arun

    Hi Arun,
    You should use this method:
    lo_nd_table->get_static_attributes_table(
    IMPORTING
    table = lt_table).
    Cheers,
    Roelof
    http://www.nl4b.com

  • Fix key fields in the Table Control

    Hi,
    Is it possible to Fix Keyfields of a table contol during scrolling in webdynpro screen.
    Regards,
    Ramu N.

    Hi Muralidaran,
                   I have no idea about WebDynpro, my requirement is that,I should inform my client whether Key Fields can be fixed just like in ALV's.
    My first task is I to inform client whether it is possible or not. Please let me know it is possible or not.
    Regards,
    Ramu N.

  • Search Help on Table Control - Fill more than one field in the table?

    Hey everyone,
    I have built a screen with a Table Control on it... the fields of the table control are linked to an internal table...  The internal table has the line type of a structure I've defined in the data dictionary.  Within that structure in the data dictionary, I've linked some fields to search helps (For example, a MATNR and CUSTOMER search help)...  I've defined in the structure definition which fields from the search help are to be returned to which fields in the structure.
    The problem is, even though I have the search help set to export both the customer number and location when using the search help on the customer field, it still does not fill the location field within the table.  Is this a limitation of using search helps within table controls?
    I'm also finding that by defining the search help through the structure, instead of directly within the screen, the search help round button does not show up on the field, yet I can still press F4 to bring up the search help.  Is there a reason why it's not showing the search help clickable button even though it works fine using F4?
    For doing search helps in Table Controls, is it better to just build the search help, attach it directly to the field in the table, and then after the user picks the single field, use the PAI to run a select and fill the rest of the fields required?
    Thanks,
    Dallas

    Hi Dallas,
    (1)
    What  i understood is that you added a search help by defining it in the internal table type for a field customer number..in the search help you have 2 fields customer number and location...user press the search help ..then you need to fill 2 different fields or 1 field?
    if you need to fill the customer location or location (only one) then you need to set the "import" in the search help for whichever is required.....
    if you need to fill 2 or more different fields..then you can use the technique you have mentioned last , to do a select in PAI and fill the fields....but this you can use if the combination for the fields is unique...eg: u have customer number and location..if customer X can be mapped to location X and location Y..when a select statement is done there are 2 options..so in such cases it is better to leave the option to the user otherwise if there is a clear mapping like customer X can be mapped only to location X then you can use the select..
    (2)
    usually when you define it as a type in the internal table the icon doesn't show up..but you can do alternative like mentioned..go to the table,find the search help for the required field if present or create a new one if required and place the search help mentioned in the screen itself..so as to see the icon...sometimes users are adamant that they need the search help icon to be seen..so it depends on if your user
    (3)
    as in the example of customer number and location mentioned we can provide them different search helps and do the needful processing in PAI to fill the fields
    Table controls may be used for different purposes and requirements....even a checkbox,push button can be placed as a field in table control and used,but yes most of the time requirements are like what is mentioned in your case...
    Regards
    Byju

  • Regarding page down in the table control veritcally

    Hi all,
              I have an issue regarding page down in the Table control in module pool , i.e when i m click the vertical scroll bar and going for page down then , the control is flowing to the next sceen which is not needed , and it shuld just scroll down and up vetically.
    Can anyone help me how to handle the page down event ?
    Thanks & regards,
    satya

    Table Controls: Examples with Scrolling
    The following example processes a table control with LOOP without parallel loop using an internal table. In addition to the scroll bar, the user can also carry out program-controlled scrolling with function codes.
    REPORT demo_dynpro_tabcont_loop.
    CONTROLS flights TYPE TABLEVIEW USING SCREEN 100.
    DATA: ok_code TYPE sy-ucomm,
          save_ok TYPE sy-ucomm.
    DATA: itab TYPE TABLE OF demo_conn,
          fill TYPE i.
          TABLES demo_conn.
    DATA: lines TYPE i,
          limit TYPE i.
    SELECT * FROM spfli INTO CORRESPONDING FIELDS OF TABLE itab.
    CALL SCREEN 100.
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'SCREEN_100'.
      DESCRIBE TABLE itab LINES fill.
      flights-lines = fill.
    ENDMODULE.
    MODULE fill_table_control OUTPUT.
      READ TABLE itab INTO demo_conn INDEX flights-current_line.
    ENDMODULE.
    MODULE cancel INPUT.
      LEAVE PROGRAM.
    ENDMODULE.
    MODULE read_table_control INPUT.
      lines = sy-loopc.
      MODIFY itab FROM demo_conn INDEX flights-current_line.
    ENDMODULE.
    MODULE user_command_0100 INPUT.
      save_ok = ok_code.
      CLEAR ok_code.
      CASE save_ok.
        WHEN 'NEXT_LINE'.
          flights-top_line = flights-top_line + 1.
          limit = fill - lines + 1.
          IF flights-top_line > limit.
            flights-top_line = limit.
          ENDIF.
        WHEN 'PREV_LINE'.
          flights-top_line = flights-top_line - 1.
          IF flights-top_line < 0.
            flights-top_line = 0.
          ENDIF.
        WHEN 'NEXT_PAGE'.
          flights-top_line = flights-top_line + lines.
          limit = fill - lines + 1.
          IF flights-top_line > limit.
            flights-top_line = limit.
          ENDIF.
        WHEN 'PREV_PAGE'.
          flights-top_line = flights-top_line - lines.
          IF flights-top_line < 0.
            flights-top_line = 0.
          ENDIF.
        WHEN 'LAST_PAGE'.
          flights-top_line =  fill - lines + 1.
        WHEN 'FIRST_PAGE'.
          flights-top_line = 0.
      ENDCASE.
    ENDMODULE.
    The layout of screen 100 is:
    A resizable table control called FLIGHTS is defined. The fields of the table control are transferred from the structure DEMO_CONN in the ABAP Dictionary. The first two columns are lead columns. The corresponding fields are output fields. A title bar, column headers, and a selection column are created. The component MARK of type character with length 1 from structure DEMO_CONN is assigned to the selection column. You can select one column and several lines.
    It has the following flow logic:
    PROCESS BEFORE OUTPUT.
      MODULE status_0100.
      LOOP WITH CONTROL flights.
        MODULE fill_table_control.
    ENDLOOP.
    PROCESS AFTER INPUT.
      MODULE cancel AT EXIT-COMMAND.
      LOOP WITH CONTROL flights.
        MODULE read_table_control.
    ENDLOOP.
      MODULE user_command_0100.
    The system executes a loop at PBO and PAI using the table control FLIGHTS. During the PBO loop, a module is called to fill the table control from table ITAB of the ABAP program. During the PAI loop, a module is called to modify table ITAB.
    Before the PBO loop, in the module STATUS_0100 the current number of lines of the internal table ITAB is placed in component LINES of control structure FLIGHTS. This helps the system to correctly install the scroll bar of the table control.
    During the PBO loop, in the module FILL_TABLE_CONTROL the work area DEMO_CONN is filled with values from the internal table, where the row index corresponds to the current row of the table control.
    During the PAI loop, in the module READ_TABLE_CONTROL the current number of the loop SY-LOOPC in the table control is placed an auxiliary variable. The number is dependent on the size of the screen. The rows of the internal table, whose row index corresponds to the current row of the table control, are overwritten with the contents of the work area DEMO_CONN. User input is transferred from the input fields of the control to the internal table. In particular, the internal table also contains a flag in the column MARK to indicate whether the row of the table control is selected or not.
    After the PAI loop, user input is processed in the module USER_COMMAND. The GUI status SCREEN_100 provides the appropriate function codes. You can scroll line by line or page by page, or Goto the first or last page. You can implement scrolling by setting the component TOP_LINE of control structure FLIGHTS. For page-by-page scrolling the auxiliary variable that is filled in the PAI loop by SY-LOOPC is used as the step size.

  • Issue while  vertical scrolling in the table control

    Hi,
    i have my table control which can show 14 entries at a time. and i have almost 100 entries in table control.
    now if i selected 2 entries in the visible part.
    now scroll vertically.
    again come back to see the selected records now they are unselected.
    please respond soon.
    Thanks
    Malya

    Hi,
    I have redone the scenario and follow the steps it will work....
    STEP 1: Create an internal table with field for selection in table.
    STEP 2: Assign the selection field in the table control for the line selection.
    STEP 3: Now whenever the line is selected, the selection field will have a field 'X'.
    STEP 4: In PAI Modify the table fields those are selected with 'X'.
    STEP 5: Set a flag in PAI, flag = 'X'.
    STEP 6: In PBO set a condition .         " We set a flag so that we fetch the data only once.
    If flag NE 'X'.
    Fetch data.
    endif.
    Data:
          begin of ztable,
             ID type char4,
             Name type char30,
             Sel type c,
          end of ztable.
    PROCESS BEFORE OUTPUT.
      MODULE STATUS_0100.
      LOOP AT ITAB INTO FS WITH CONTROL EMP CURSOR W_I.
        MODULE UPDATE.
      ENDLOOP.
    PROCESS AFTER INPUT.
      LOOP AT ITAB.
      MODULE APPEND.
      ENDLOOP.
      MODULE USER_COMMAND_0100.
    INCLUDE YMODTOP                                 .    " global Data
    *&      Module  UPDATE  OUTPUT
    *       text
    MODULE UPDATE OUTPUT.
      MOVE FS TO FS.
    ENDMODULE.                 " UPDATE  OUTPUT
    *&      Module  STATUS_0100  OUTPUT
    *       text
    MODULE STATUS_0100 OUTPUT.
      IF FL_FLAG <> 1.
        SELECT * FROM ZTABLE INTO CORRESPONDING FIELDS OF TABLE ITAB.
      ENDIF.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  append  INPUT
    *       text
    MODULE APPEND INPUT.
      MODIFY ITAB INDEX SY-STEPL FROM FS TRANSPORTING SEL .
      FL_FLAG = 1.
    ENDMODULE.
    Thanks&Regards
    Sarves

  • New columns in the table control do not appear

    Hi,
    We have a requirement to add two fields(columns) in a table control  for a transaction upon clicking Create button and those two fields should be editable. We have added the two fields in the table control. But, they do not appear in the transaction ( If I delete an existing column, then I am able see the new column).  Have checked everywhere, but not sure if I am missing something here. There is no hide statement used.
    Appreciate help on this.
    Thanks,
    Pavan

    Hi Pavan,
    What I understood is you are adding fields to the table control dynamically.\
    For that you have to use field-symbols to add fields to the work area dynamically.
    ( If this is not your actual requirement share your code with me I will try to solve it. )
    Regards,
    Swaroop

  • Adding an extra line in the table control

    Hi All,
    How can we add an extra record in the table control after the user hits ADD button?We tried doing it by incrementing the lines field in the table control,but it is executing the PBO part again after hitting the ADD button.Any SAP standard program will be helpful.
    Thanks,
    Rakesh.

    Hi,
    I think you can do that by inerting new line to Internal table that used in your Table Control. Here the sample:
    TC_DATA = Your Table Control
    IT_DATA = Your Internal Table used for Table Control.
    In your MODULE USER_COMMAND INPUT, add this code:
    IF OK_CODE = 'ADD'.
      CLEAR: IT_DATA.
      APPEND IT_DATA.
    ENDIF.
    Regards,

  • New fields to MM01 Table Control

    Hi All,
    My requirement is to add the LAENG (Length), BREIT(Width) and HOEHE(Height) fields to the table control in AFS Weights and Volumes TabStrip of MM01 Transaction and we need to update these values in /AFS/MARM table. This is an AFS System.
    I have copied the Function Group J3AB to ZJ3AB and modified the sub screen 2501. I am to see my custom sub screen. But when I change the data in the table control the data is not getting saved in the /AFS/MARM table.
    There is an internal table XJ_3AMARM which holds the table control data. This table is declared as the global field in the function group. It is getting populated in the PAI of my custom screen. But when the control goes to SAP standard function group the data is getting refreshed and data is not getting updated.
    Please suggest me in updating the data.
    Thanks & Regards,
    Prasad.

    Hi,
    Add a field in the internal table structure of editor program.
    and select the data into it.
    Go to screen painter and go to layout, add your new field by selecting   dictionary field or internal table field. If you select the dictionary field , then you have to assign it to a value in the PBO module.
    PBO.
    module assign.
    in se38
    module assign output.
    dictionary-field = internal table field.
    endmodule.
    regards,
    kamala.

  • Custom fields for FV50 table control

    Hello,
    The customer has a requirement to add 3 text fields to the table control in Transaction FV50. These fields are currently not available in the table control at all (I checked the Table settings Administrator). Further, no Screen/Transaction Variant has been implemented either to prevent these fields from being displayed. Which is why I'd like to find a way to add these custom fields to this table control. These fields are the text descrptions for the numeric fields Cost Center, Fund and Business Area.
    I've read many posts on this forum regarding potential solutions including the link below which details the SAP std solution. Only problem is this approach adds these fields to the data dictionary tables underlying the screen. The customer says about 1 million records are being generated a month so they would rather not have all that extra data at the line item level.
    Custom column for FB60
    If anybody has done this sort of thing via a user exit I'd much appreciate your input.
    Thanks,
    Tarun

    Hi Rob,
    Yes, I checked IMG configuration and found that Txn OXK3 allows us to extend the underlying tables and customize the generic fields in the table control. However, the client  has nearly 1 million postings to table BSEG each month and I'm guessing this approach will entail adding the custom fields to table BSEG, which won't work for them. I haven't actually tried this approach because the SAP documentation has some dire warnings about proceeding. But if you have any insight as to whether this can be achieved without extending BSEG (possibly just extend VBSEGS??) that would be very valuable.
    Thanks,
    Tarun

  • Want to add field in standard table control - me21n , me22n , me23n

    Dear All ,
    I have come across a situation where I want to add a field in a standard table control .
    But how to proceed for tht I am not getting .
    In the standad transation me22n in the ITEM  OVERVIEW table control I want to add Curreny field in the table control structure
    i.e MEPO1211 I have append the field in MEPO1211_DATA it is even visible in run time in the structure but not visible in table control and in table control settings also.
    How can I add one more column or some standard procedure to do that. Please suggest .
    Thanks & Regards
    Aryan

    hi,
    If you don't want to access key...then only option is ,you have to search USER Exit or BADi (Try using BADI ME_GUI_PO_CUST) for me22n transaction......to adding the field.
    Regards
    Gaurav

  • How to change the screen element of a single field in a table control

    Hi Gurus,
    I want to change the screen element of a single field (or the whole row) in a table control according to a condition.
    I have 2 columns in the table control. One is an input column and one output only. When user enters values into the input column, they need to be compared against the values in the other column, and if there is a discrepancy, the row where the discrepancy is needs to be highlighted.
    I have tried the following code which highlights the whole column ...
    CONTROLS: TC_ZVOYG_BINS TYPE TABLEVIEW USING SCREEN 0500.
    DATA: wa_tc_zvoyg_col LIKE LINE OF TC_ZVOYG_BINS-cols.
      LOOP AT G_TC_ZVOYG_BINS_ITAB
               INTO G_TC_ZVOYG_BINS_WA.
        if G_TC_ZVOYG_BINS_WA-zdelivery_bin ne G_TC_ZVOYG_BINS_WA-zactual_bin.
          loop at screen.
            IF screen-name = 'ZVOYG_BINS-ZACTUAL_BIN'.
              wa_tc_zvoyg_col-screen-intensified = 1.
              MODIFY tc_zvoyg_bins-cols FROM wa_tc_zvoyg_col TRANSPORTING
              screen-intensified WHERE screen-name = screen-name.
            endif.
          endloop.
        endif.
      endloop.
    And also the following code which makes no change ...
      LOOP AT G_TC_ZVOYG_BINS_ITAB
               INTO G_TC_ZVOYG_BINS_WA.
        if G_TC_ZVOYG_BINS_WA-zdelivery_bin ne G_TC_ZVOYG_BINS_WA-zactual_bin.
          loop at screen.
            IF screen-name = 'ZVOYG_BINS-ZACTUAL_BIN'.
              screen-intensified = '1'.
              modify screen.
            endif.
          endloop.
        endif.
      endloop.
    Thanks in advance.

    Hi,
    The modification of a screen element attribute (LOOP AT SCREEN...MODIFY SCREEN) must always be done in the PBO (for a dynpro, it will be in a PBO module, i.e. declared by MODULE ... OUTPUT)
    About the loop at the internal table, it is done automatically by the system, also during the PBO, you'll find something like LOOP [AT itab] ... WITH CONTROL ...  in the PBO part of the screen flow logic (note: you may have to complete with a supplementary READ TABLE if you don't use AT itab). So you don't need an additional loop.
    Best regards
    Sandra

Maybe you are looking for

  • Issue in footer display in PDF doc. where in smartforms footer is displayed correctly

    I have created a smart forms and done some work around to display a footer on the last page only then by changing it into OTR for PDF display. I am getting the Form output as it was required but am not getting the PDF ditto same as smart form output

  • JDeveloper installation not working with Java 1.7 Update 11

    Hi, I am trying to install jDeveloper (11.1.1.6.2) for Fusion Applications Release 4 using Java 1.7 and its failing with a fatal error. I am on Mac Lion Version 10.7.5. Any ideas how to overcome this !?

  • How to export the source from a Jdeveloper to another Jdeveloper?

    Help me. In my company I have begun to write a Java Web Application with Struts using Jdeveloper. I have the necessity to move all the project in my laptop, work on it and after move another time the project into the PC of my firm and so on. How i ca

  • Warning message on MRP view

    Hi consultants, I have a material that is specified as "External Procurement" Material.   It is because it's a Subcon material.  In line with this, a production version is maintained due to some business process requirement, which the system allows. 

  • Recording wih a mixer

    Hey, I just got a new mixer that connects via a USB cable. I use it to record voices and such for my movies. I already figured out how to record with it into Final Cut. But, say I am using 2 different mics on the mixer. When I record, it records the