How Highlight a CELL on an ALV table

Hi all!
I'm trying to do some checks on an input field of an ALV table component. But using REPORT_ATTRIBUTE_T100_MESSAGE it doesn't highlight the CELL of the row if the check hasn't been passed succesfully.
I've used this source code but nothing appears on the screen, no message and no cell highlighted. I put my source code for more information:
LOOP AT lt_data_mod INTO ls_data_mod.
alternative access via index
lo_el_n_empleado = lo_nd_n_empleado->get_element( index = ls_data_mod-index ).
CHECK VALUE
report message
CALL METHOD wd_comp_controller->go_message->report_attribute_t100_message
EXPORTING
msg = ls_msg
element = lo_el_n_empleado
attribute_name = ls_data_mod-attribute. " The name of input field that it is being modified
All that source code is in ON_DATA_CHECK event of ALV component.
Can anyone help me ?
Thanks!

Hello,
I put my source code:
ON_DATA_CHECK event of ALV:
  lt_data_mod[] = lr_data->t_modified_cells[].
  LOOP AT lt_data_mod INTO ls_data_mod.
alternative access  via index
lo_el_n_empleado = lo_nd_n_empleado->get_element( index = ls_data_mod-index ).
get all declared attributes
    lo_el_n_empleado->get_static_attributes(
      IMPORTING
        static_attributes = ls_n_empleado ).
Leemos la información inicial para hacer posteriormente los recalculos.
    READ TABLE wd_this->gt_empleados_inicial INTO ls_empleados_inicial WITH KEY pernr = ls_n_empleado-pernr.
    ASSIGN ls_data_mod-r_value->* TO .
Fijamos el valor del campo INCIN o PERIN en función de si el usuario ha modificado el valor en pantalla
    IF ls_data_mod-r_value NE ls_data_mod-r_old_value AND
        GE ls_n_empleado-incsu.
      IF ls_data_mod-attribute = 'INCPA'.
        ls_n_empleado-incin = abap_true.
      ELSEIF ls_data_mod-attribute = 'PERVC'.
        ls_n_empleado-perin = abap_true.
      ENDIF.
ELSEIF <fs_data> LT ls_n_empleado-incsu. " Check if user entry is less than incsu value then throw message...
      wd_comp_controller->show_message_2( imp_element = lo_el_n_empleado
                                                                           imp_msgno   = '622'
                                                                           imp_attr    = ls_data_mod-attribute ). " El valor introducido es menor que el "                 incremento sugerido
    ENDIF.
METHOD show_message_2 .
  DATA lv_message_id TYPE string.
  DATA ls_msg TYPE symsg.
  ls_msg-msgty = 'E'.
  ls_msg-msgid = 'ZHR_CM'.
  ls_msg-msgno = imp_msgno.
report message
  CALL METHOD wd_this->go_message->report_attribute_t100_message
    EXPORTING
      msg            = ls_msg
      element        = imp_element
      attribute_name = imp_attr.
ENDMETHOD.
Also I've tried with report_element_t100_message method but nothing happens.
Thank you.
Edited by: vanbelal on Mar 22, 2010 4:54 PM

Similar Messages

  • How to include tool bar in alv table?

    Dear All,
        I want to know how to use tool bar in alv table? Is there any seperate interfaces available for it?
    Thanks,
    Gopi.

    Hi,
    1.To deactivate the Standard buttons:
    Data: lr_config_table TYPE REF TO cl_salv_wd_config_table,
    lo_value = lo_interfacecontroller->get_model( ).
    lr_config_table ?= lo_value .
    Wd_this->lr_config_table  ?= lo_value .
      lr_config_table->if_salv_wd_std_functions~set_edit_append_row_allowed( abap_false ).
      lr_config_table->if_salv_wd_std_functions~set_edit_insert_row_allowed( abap_false ).
      lr_config_table->if_salv_wd_std_functions~set_edit_delete_row_allowed( abap_false ).
    2.To create the customized buttons:
    Create the a method initilaze_buttons.
    Data:lv_function_add_record_sap          TYPE REF TO cl_salv_wd_function,
          lv_button_add_record_sap             TYPE REF TO cl_salv_wd_fe_button,
           R_ALV_TABLE_COMP  type ref to CL_SALV_WD_CONFIG_TABLE.
    r_alv_table_comp = wd_this->lr_config_table.
    Generate Function Objects
    lv_function_add_record_sap = wd_this->lr_config_table->if_salv_wd_function_settings~create_function( 'ADD_RECORD_SAP' ).
    Generate Buttons
      CREATE OBJECT lv_button_add_record_sap.
      lv_button_add_record_sap->set_image_source( 'ICON_INSERT_ROW' ).
    lv_button_add_record_sap->set_text( 'Add Record' ).
    Assign Buttons to Functions
    lv_function_add_record_sap->set_editor( lv_button_add_record_sap ).
    Set positions of the buttons
      lv_function_add_record_sap->set_position( value = 1 ).
    Set Alignment of the buttons
    lv_function_add_record_sap->set_alignment( value = if_salv_wd_c_function_settings=>align_left ).
    Call this method initilaze_buttons in WDDOINIT .
    3.To find out which button is clicked an dhandling that function
    A)Go to methods tab.
    B)give the name of the method as on_button select the method type as Eventhandler.
    In the event coulmn select the event ON_FUNCTION of the ALV comp.
    METHOD on_button .
      DATA index  TYPE i.
      index = wd_this->sort_index .
      CASE r_param->id."r_param->id is importing paramter which comes automatically once u use the event handler
        WHEN 'DELETE_ROW'.  "Delete row
          wd_this->delete_row( )."methods you need to create and call them here.(your own customized button functionality
        WHEN 'ADD_RECORD_SAP'.
          wd_this->add_record_sap( ).
    ENDCASE.
    r_param->id holds the value which button is clicked.
    Priya

  • How to get one column of ALV table as dropdown by key.

    Hi experts,
                  How can I get one column of ALV table as dropdown and editable. If  user wants to change that column value he can just select from that dropdown and click on update button. Can I provide tool tip to that column as " Select from drop down to change the status "?
      Please Help.
    Thanks,
      Pratibha

    You just need to change the cell editor of that column in ALV.
    So first get access to the alv model object (adjusting the code below for your ALV Component Usage name - mine was ALV_ADV):
    DATA: l_ref_cmp_usage TYPE REF TO if_wd_component_usage.
      l_ref_cmp_usage =   wd_this->wd_cpuse_alv_adv( ).
      IF l_ref_cmp_usage->has_active_component( ) IS INITIAL.
        l_ref_cmp_usage->create_component( ).
      ENDIF.
      DATA l_salv_wd_table TYPE REF TO iwci_salv_wd_table.
      l_salv_wd_table = wd_this->wd_cpifc_alv_adv( ).
      DATA l_table TYPE REF TO cl_salv_wd_config_table.
      l_table = l_salv_wd_table->get_model( ).
    Then access the column object you want to change:
    DATA l_column TYPE REF TO cl_salv_wd_column.
      l_column = l_table->if_salv_wd_column_settings~get_column( 'REGION' ).
    Then create the cell editor for DDLB and set it as the new cell editor for this column:
    DATA ddlb TYPE REF TO cl_salv_wd_uie_dropdown_by_key.
      create object ddlb
        exporting
          selected_key_fieldname = 'REGION'.
      ddlb->set_tooltip( `Select from drop down to change the status` ).
      l_column->set_cell_editor( ddlb ).

  • How To Edit Selected Row In ALV Table

    Hello Experts,
    In My Webdynpro Application, I am displaying records from database table into an ALV Table.
    I want to edit only selected record from  ALV table.
    Please Suggest How to achieve this.
    Thanks,
    Pratibha

    The link given above is for the UI element 'Table' and does not pertain to ALV.
    To Make an ALV Editable on lead selection for that particular lead selected row.
    1. The ALV should be made lead selectable, when initializing
    2. The ON_LEAD_SELECT function should be invoked.
    3. Withing this function the index has to be retrieved to know which row was selected.
    4. Based on the index retrived all the columns have to pass FALSE to read_only in the column properties.
    Regards,
    Pramod

  • How to process Line Selection on ALV Table in ABAP WebDynpro

    Hi there,
    I have a view with an ALV table whose context node retrieves its data from a Service Call for a method.
    The method provides certain data of a database table which the ALV displays.
    Now I would like to be able to select one row of that ALV table and after pressing a button or doubleclicking on the row or whatever a different view (as for me it is also ok on the same view) should appear to display the details of that selection.
    I only need to know how to retrieve the selected data.
    Or its index within the internal table.
    I am already looking for hours for a useful thread and actually there is one which obviously is about a similar issue apart from the multiple selection part: 
    How to process multiple row selection in ALV table in Wendynpro ABAP? Help!
    but i am afraid that i don't understand it. Or at least I misunderstand it since it does not work with me.
    The system example mentioned in the thread does not help me either because it somehow does not correspond to my needs, does it?
    It would be GREAT if somebody could help me with that. Please keep it simple for I am not an expert in webdynpro yet (obviously ^^) and also please explain in detail what I have to do with the context nodes since I am not sure whether the selection is stored in my already existing node or whether I need a special one for that.
    Thanks!!
    christina

    Hi Christina,
    If you just want to get one column data of the line that user clicked, use the Web Dynpro Code Wizard to Read Context of attibute you needed, then you will get code as follow:
    * Define data for read attribute
        node_alv TYPE REF TO if_wd_context_node,
        elem_alv TYPE REF TO if_wd_context_element,
        stru_alv TYPE if_view_display=>element_alv ,
        item_column_name  LIKE stru_alv-column_name.
    * navigate from <CONTEXT> to <ALV> via lead selection
      node_alv = wd_context->get_child_node( name = if_view_display=>wdctx_alv ).
    * get element via lead selection
      elem_alv = node_alv->get_element(  ).
    * get single attribute
      elem_alv->get_attribute(
        EXPORTING
          name =  `COLUMN_NAME'
        IMPORTING
          value = item_column_name ).
    The value of column_name is stored in item_column_name.
    If you need the index that the user clicked, try this:
    * Definition of field symbol for index
      FIELD-SYMBOLS : <fs_index> TYPE data.
    * Get the selected index
      ASSIGN r_param->index->* TO <fs_index>.
    The index of clicked line is stored in field symbol <fs_index>.
    Hope it will help.
    Best Regards,
    Stephanie

  • How to remove a column from alv table

    Hi All
    How to remove a specific column from alv table.?
    Thanks & Regards
    SUN

    For delete u can follow the above post..
    Fo making invisible :
    data m_col type ref to cl_salv_wd_column.
    m_col = alv_mode->IF_SALV_WD_COLUMN_SETTINGS->GET_COLUMN (' col1' ).
    m_col->SET_VISIBILITY( '01'  ).

  • How to unhide the column in Alv table

    Hi Experts,
        Initially i have created webdynpro Alv table with 8 columns ,later i have added one more attribute/column to the node to display extra column
    but in the output ,alv table not displaying the 9th column,Instead the column is getting hidden which i came to know clicking on settings in alv table output.If i make changes in Alv table settings it getting displaying,can anyone tell me how to unhide this field.
    Regards
    Sandesh

    Hi Sandesh,
         It is possible that the user you are loggin in with, might have a layout saved.
    You can try logging in with different user and see if its still hidden.
    The explicit code to hide and unhide a column :
    lo_alv_column->set_visible( if_wdl_core=>visibility_none ).
    may be  you can use the above code and make column visibility true(cahnge parameter).
    Regards,
    Tashi

  • WDABAP - How to read data from filtered ALV table

    HI
    In Web Dynpro for ABAP.
    I have a view with an ALV table on it.
    I would like to know how to read the data that's been filtered in the ALV table?
    Regards

    I've managed to find out that during runtime the following code returns a reference to a class pool:
    data: lr_salv_wd_table TYPE REF TO iwci_salv_wd_table.
    lr_salv_wd_table = wd_This->wd_cpIfc_ALV_GRAPHICS_DATA( )
    Two of the attributes of this class pool are:
              <b>IG_COMPONENTCONTROLLER~R_COMPONENT =    </b>                                       
    <b>          IF_COMPONENTCONTROLLER~R_COMPONENT =    </b>
    The attributes, IG_COMPONENTCONTROLLERR_COMPONENT and IF_COMPONENTCONTROLLERR_COMPONENT references a class CL_SALV_WD_C_TABLE. This class has an attribute R_RESULT_DATA which references a class CL_SALV_WD_RESULT_DATA_TABLE. The attribute T_RESULT_DATA contains the filtered data.
    Now I need to find out how I can access these attributes in the view.
    Regards

  • How to merge the Rows in ALV table?

    Hi All,
    I want to merge the Rows in my ALV table(SALV_WD_TABLE). Is it possible?
    Regards,
    Yugesh A.

    Yogi1729 wrote:
    Hi All,
    how to Restrict the Row in the Pivot table.
    My Requirement is like this.
    i have to show the top 10 values in the pivot table but My report is show all the values.
    how can we achieve this.
    any quick solution for this appreciated.
    Thanks,
    Yogi.You can't really restrict the rows in a pivot table, but you can do this:
    http://oraclebizint.wordpress.com/2008/01/17/oracle-bi-101332-pagination-in-pivot-tables/

  • How to make cell editable in ALV

    Hello all,
    I have following scenario.
    I am using ALV_GRID_DISPLAY.
    I have 5 field on output screen say A , B , C , D , E.
    In field A  i have check box.
    In field B i have number like 0 ,1 , 2 , 3 ,4 ,5.
    My problem is whenever i get value of field A as 0 i want to make my only check box of that row  editable.
    So can anyone help me.
    Thanks in advance
    Sachin

    Hi Sachin,
    REPORT zalv_editf4display.*Type pools for alv
    TYPE-POOLS : slis.*structure for t582a tbale
    TYPES : BEGIN OF ty_table,
            infty TYPE infty,
            pnnnn TYPE pnnnn_d,
            zrmkz TYPE dzrmkz,
            zeitb TYPE dzeitb,
            dname TYPE dianm,
             davo TYPE davo,
            davoe TYPE davoe,
            END OF ty_table.*Structure for infotype text
    TYPES : BEGIN OF ty_itext,
            infty TYPE infty,
            itext TYPE intxt,
            sprsl TYPE sprsl,
            END OF ty_itext.*Structure for output display
    TYPES : BEGIN OF ty_output,
            infty TYPE infty,
            itext TYPE intxt,
            pnnnn TYPE pnnnn_d,
            zrmkz TYPE dzrmkz,
            zeitb TYPE dzeitb,
            dname TYPE dianm,
            davo TYPE davo,
            davoe TYPE davoe,
           END OF ty_output.*internal table and work area declarations
    DATA : it_table TYPE STANDARD TABLE OF ty_table INITIAL SIZE 0,
           it_output TYPE STANDARD TABLE OF ty_output INITIAL SIZE 0,
           it_pbo TYPE STANDARD TABLE OF ty_output INITIAL SIZE 0,
           it_ittext TYPE STANDARD TABLE OF ty_itext INITIAL SIZE 0,
           wa_table TYPE ty_table,
           wa_output TYPE ty_output,
           wa_ittext TYPE ty_itext.*Data declarations for dropdown lists for f4
    DATA: it_dropdown TYPE lvc_t_drop,
          ty_dropdown TYPE lvc_s_drop,
    *data declaration for refreshing of alv
          stable TYPE lvc_s_stbl.*Global variable declaration
    DATA: gstring TYPE c.
    *Data declarations for ALV
    DATA: c_ccont TYPE REF TO cl_gui_custom_container,         "Custom container object
          c_alvgd         TYPE REF TO cl_gui_alv_grid,         "ALV grid object
          it_fcat            TYPE lvc_t_fcat,                  "Field catalogue
          it_layout          TYPE lvc_s_layo.                  "Layout*ok code declaration
    DATA:
      ok_code       TYPE ui_func.
    initialization eventINITIALIZATION.start of selection event
    START-OF-SELECTION.*select the infotypes maintained
      SELECT infty
              pnnnn
              zrmkz
              zeitb
              dname
              davo
              davoe
              FROM t582a UP TO 10 ROWS
              INTO CORRESPONDING FIELDS OF TABLE it_table.* *Select the infotype texts
      IF it_table[] IS NOT INITIAL.
        SELECT itext
                 infty
                 sprsl
                 FROM t582s
                 INTO CORRESPONDING FIELDS OF TABLE it_ittext
                 FOR ALL ENTRIES IN it_table
                 WHERE infty = it_table-infty
                 AND sprsl = 'E'.
      ENDIF.
    *Apppending the data to the internal table of ALV output
      LOOP AT it_table INTO wa_table.    wa_output-infty = wa_table-infty.
        wa_output-pnnnn = wa_table-pnnnn.
        wa_output-zrmkz = wa_table-zrmkz.
        wa_output-zeitb = wa_table-zeitb.
        wa_output-dname = wa_table-dname.
        wa_output-davo = wa_table-davo.
        wa_output-davoe = wa_table-davoe.* For texts    READ TABLE it_ittext INTO wa_ittext WITH KEY infty = wa_table-infty.
        wa_output-itext = wa_ittext-itext.
        APPEND wa_output TO it_output.
        CLEAR wa_output.  ENDLOOP.* Calling the ALV screen with custom container  CALL SCREEN 0600.*On this statement double click  it takes you to the screen painter SE51.
    *Enter the attributes
    *Create a Custom container and name it CCONT and OK code as OK_CODE.
    *Save check and Activate the screen painter.
    *Now a normal screen with number 600 is created which holds the ALV grid.
    PBO of the actual screen ,
    Here we can give a title and customized menus
    *create 2 buttons with function code 'SAVE' and 'EXIT'.
    GIVE A SUITABLE TITLE&---------------------------------------------------------------------
    *&      Module  STATUS_0600  OUTPUT
          text
    MODULE status_0600 OUTPUT.
      SET PF-STATUS 'DISP'.
      SET TITLEBAR 'ALVF4'.
    ENDMODULE.                 " STATUS_0600  OUTPUT
    calling the PBO module ALV_GRID.
    *&      Module  PBO  OUTPUT
          text
    MODULE pbo OUTPUT.*Creating objects of the container
      CREATE OBJECT c_ccont
           EXPORTING
              container_name = 'CCONT'.*  create object for alv grid
      create object c_alvgd
      exporting
      i_parent = c_ccont.*  SET field for ALV
      PERFORM alv_build_fieldcat.* Set ALV attributes FOR LAYOUT
      PERFORM alv_report_layout.
      CHECK NOT c_alvgd IS INITIAL.* Call ALV GRID  CALL METHOD c_alvgd->set_table_for_first_display
        EXPORTING
          is_layout                     = it_layout
          i_save                        = 'A'
        CHANGING
          it_outtab                     = it_output
          it_fieldcatalog               = it_fcat
        EXCEPTIONS
          invalid_parameter_combination = 1
          program_error                 = 2
          too_many_lines                = 3
          OTHERS                        = 4.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                   WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.ENDMODULE.                 " PBO  OUTPUT&----
    *&      Form  alv_build_fieldcat
          text
         <--P_IT_FCAT  text
    *subroutine to build fieldcatFORM alv_build_fieldcat.  DATA lv_fldcat TYPE lvc_s_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '1'.
      lv_fldcat-fieldname = 'INFTY'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 8.
      lv_fldcat-scrtext_m = 'Infotype'.
      lv_fldcat-icon = 'X'.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '2'.
      lv_fldcat-fieldname = 'PNNNN'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Structure'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '3'.
      lv_fldcat-fieldname = 'ITEXT'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 60.
      lv_fldcat-scrtext_m = 'Description'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '5'.
      lv_fldcat-fieldname = 'ZRMKZ'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 1.
      lv_fldcat-scrtext_m = 'PERIOD'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '6'.
      lv_fldcat-fieldname = 'ZEITB'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 5.
      lv_fldcat-scrtext_m = 'Time constraint'.
      lv_fldcat-edit = 'X'.
    *To avail the existing F4 help these are to
    *be given in the field catalogue
      lv_fldcat-f4availabl = 'X'.
      lv_fldcat-ref_table = 'T582A'.
      lv_fldcat-ref_field = 'ZEITB'.  APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '7'.
      lv_fldcat-fieldname = 'DNAME'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Dialogmodule'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '8'.
      lv_fldcat-fieldname = 'DAVO'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Start'.
      lv_fldcat-edit = 'X'.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.  lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '9'.
      lv_fldcat-fieldname = 'DAVOE'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'End'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
    *To create drop down for the field 'DAVO'
    with our own f4 help
      ty_dropdown-handle = '1'.
      ty_dropdown-value = ' '.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '1'.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '2'.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '3'.
      APPEND ty_dropdown TO it_dropdown.  CALL METHOD c_alvgd->set_drop_down_table
        EXPORTING
          it_drop_down = it_dropdown.
      LOOP AT it_fcat INTO lv_fldcat.
        CASE lv_fldcat-fieldname.
    To assign dropdown in the fieldcataogue
          WHEN 'DAVO'.
            lv_fldcat-drdn_hndl = '1'.
            lv_fldcat-outputlen = 15.
            MODIFY it_fcat FROM lv_fldcat.
        ENDCASE.
      ENDLOOP.ENDFORM.                    " alv_build_fieldcat&----
    *&      Form  alv_report_layout
          text
         <--P_IT_LAYOUT  text
    *Subroutine for setting alv layout
    FORM alv_report_layout.
      it_layout-cwidth_opt = 'X'.
      it_layout-col_opt = 'X'.
      it_layout-zebra = 'X'.ENDFORM.                    " alv_report_layout* PAI module of the screen created. In case we use an interactive ALV or
    *for additional functionalities we can create OK codes
    *and based on the user command we can do the coding.
    *&      Module  PAI  INPUT
          text
    MODULE pai INPUT.*To change the existing values and refresh the grid
    *And only values in the dropdown or in the default
    *F4 can be given , else no action takes place for the dropdown
    *and error is thrown for the default F4 help and font changes to red
    and on still saving, value is not changed  c_alvgd->check_changed_data( ).Based on the user input
    *When user clicks 'SAVE;
      CASE ok_code.    WHEN 'SAVE'.*A pop up is called to confirm the saving of changed data
          CALL FUNCTION 'POPUP_TO_CONFIRM'
            EXPORTING
              titlebar       = 'SAVING DATA'
              text_question  = 'Continue?'
              icon_button_1  = 'icon_booking_ok'
            IMPORTING
              answer         = gstring
            EXCEPTIONS
              text_not_found = 1
              OTHERS         = 2.
          IF sy-subrc NE 0.
          MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                  WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ENDIF.*When the User clicks 'YES'
          IF ( gstring = '1' ).
            MESSAGE 'Saved' TYPE 'S'.
    *Now the changed data is stored in the it_pbo internal table
            it_pbo = it_output.
    *Subroutine to display the ALV with changed data.
            PERFORM redisplay.
          ELSE.
    *When user clicks NO or Cancel
            MESSAGE 'Not Saved'  TYPE 'S'.
          ENDIF.
    **When the user clicks the 'EXIT; he is out
        WHEN 'EXIT'.
          LEAVE PROGRAM.
      ENDCASE.  CLEAR: ok_code.ENDMODULE.                 " PAI  INPUT
    *&      Form  REDISPLAY
          text
    -->  p1        text
    <--  p2        text
    FORM redisplay .*Cells of the alv are made non editable after entering OK to save  CALL METHOD c_alvgd->set_ready_for_input
        EXPORTING
          i_ready_for_input = 0.*Row and column of the alv are refreshed after changing values  stable-row = 'X'.
      stable-col = 'X'.*REfreshed ALV display with the changed values
    *This ALV is non editable and contains new values
      CALL METHOD c_alvgd->refresh_table_display
        EXPORTING
          is_stable = stable
        EXCEPTIONS
          finished  = 1
          OTHERS    = 2.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.ENDFORM.                    " REDISPLAY
    Regards,
    Flavya

  • How to set title/text for ALV table column header in WD ABAP

    Hello,
    I am working in WDA using SALV_WD_Table to display data in table. I need to change the column header text, the obvious way is to get the column header and call the method SET_TEXT to set new text / title. However, this method does NOT work, it does not change the column header text. I also tried the SET_TOOLTIP, this one works, but SET_TEXT does not work. Anyone has idea why this not working and do you find any go-around solution?
    My version is NW 7.0
    Thank
    Jayson

    Hi jason ,
    For setting Heder text for your ALV table
    ip_confing type ref to CL_SALV_WD_CONFIG_TABLE.
    "set alv table header
      ip_config->if_salv_wd_table_settings~r_header->set_text( 'Test ALV Header functionality' ).
    first you have to hide the DDIC text and then try to set your own text .
    "modify columns
      LOOP AT lt_columns INTO ls_column.
        lr_column = ls_column-r_column.
        CASE ls_column-id.
          WHEN 'MANDT'.
            "hide this field
            lr_column->set_visible( cl_wd_abstr_table_column=>e_visible-none ).
           WHEN 'SEQNR'.
            "set header to different string
            lr_column->r_header->set_ddic_binding_field( if_salv_wd_c_column_settings=>ddic_bind_none )." use this line to hide ddic text
            lr_column->r_header->set_text( 'Position' ).     
        endcase.
      endloop.
    Regards
    Chinnaiya P

  • How to remove white seperators in ALV Table columns names?

    Hi,
    I am trying to remove white seperators which appeared dynamically on using ALV table on each of the column names. I checked in ALV API's but could not find anything there to remove code wise. Please help to remove this.
    Thanks
    Praveen

    Hi Praveen,
    Please use the following method.
      DATA lo_table  TYPE REF TO cl_salv_wd_config_table.
      CALL METHOD lo_table->if_salv_wd_std_functions~set_sort_headerclick_allowed( EXPORTING value  = abap_false ) .
    Regards,
    Manogna

  • How to keep lead selections in alv table...

    Hi experts.
    I made a alv.
    A logic  in wdmodifyview is following..
    METHOD wddomodifyview .
      IF first_time EQ abap_true.
        wd_comp_controller->set_alv_config( ).
      ENDIF.
      wd_this->set_maktx( ).  "<- for displaying maktx
    ENDMETHOD.
    When I want to select a line, do not selected.
    I know because of "wd_this->set_maktx( )." sentence.
    But I want to select multi lines in above condition...
    How to keep selected lines in alv?
    Help me please.
    Thanks.
    Regards.

    What logic is taking place in wd_this->set_maktx( )?  It is pretty difficult to say what is causing the issue without knowing what code you are executing?  If you are resetting the context bound to the ALV, that would explain why you are losing your selections.

  • How to set cell attributes in a table line ?

    Hello,
    In a PDF form (SFP) , When I loop to display a table, Some conditions will be checked such as the Invoice amount > 1000 , then this cell will be printed in BOLD and Underlined . I think that we will use Java scipt at client But I do not know how to check a cell value and set attribute for a cell. ( BOLD and UNDERLINE)
    Could you please help me ?
    Thanks in advance .

    First of all: do not use table (like the MS Word table). Create a tale "look and feel" using subforms: one for row and one for the table. Then accessing the row and its value is not a problem and has been explained many times here or in the manuals. The same way you will manipulate the font properties of the cells.
    Otto

  • How to merge cells in an ADF Table??

    I have to make a ADF Table in which user should be able to select adjacent cells and when clicked on a merge button these cells should be merged..
    Does any one have example on this??

    Hi,
    you can't since table cells are components and not just markup.
    Frank

Maybe you are looking for

  • HT1904 How can I get a refund for apps in the apple App Store that do not work and are not what they said they wer

    How can I get a refund for apps in the apple App Store that do not work and are not what they said they wer

  • Search Button in IH01/IH03 Not active

    Hi Experts, In E.C.C 6.0 version i find that the search button in IH01/IH03 -Structure display appears as Grayed and is inactive. I think my changing the parameter PM_TREE_INACTIVE  = X in Parameter settings for a user, it  can be made active.But my

  • Lost pictures in iPhoto

    I can see some pictures in iPhoto but when I open some of them, a sign ( "!" into a white circle) appears and if I ask to see the file, I can not find the file on my laptop. The problem happen with several pictures and if I want to find the using Fin

  • CUPS 6.0.6 and CUPC 7.0.x DeskPhone Mode not working

    Hi Everyone, we got a Problem when enabling DeskPhone in the CUPC. Serverhealth shows me "invalid credentials". When i take a look at the trace from CTIManager i get the following Errors: CTI|Available Servers (2)|<CLID::StandAloneCluster> CTI|authen

  • Adobe Acrobat 8 & 9 crash when I hit print.  Fix?

    Process:         AdobeAcrobat [630] Path:            /Applications/Adobe Acrobat 9 Pro/Adobe Acrobat Pro.app/Contents/MacOS/AdobeAcrobat Identifier:      com.adobe.Acrobat.Pro Version:         9.1.0 (9.1.0) Code Type:       X86 (Native) Parent Proces