Editable alv using checkboxes.

Hi All,
I am working on editable alv using checkboxes.I have few requirements.
1) i have all checkboxes in my row.If i select the Row fieldname all of my checkboxes hsould be checked.
2) in my internsl table i have field called comments.If comment field has space i need to disable the checkbox.If comment is filled then i need to enable the chekkbox.
Field catalog need to be changed based on my internal table.
Can anybody please let me know how can i solve the above issues.
Thanks
Swapna.

1. There is no event for this (row of column), so this will not be possible.
2. Check report BCALV_EDIT_05.

Similar Messages

  • Editable ALV with checkbox, how to use on_change event

    Hi experts,
    I used an editable  ALV. In firs collumn I Used an cell editor checkbox (cl_salv_wd_uie_checkbox). I neet to react on each click on each checkbox in order to do some actions in context, that is not part (mapped) to ALV.
    There are IF_SALV_WD_CONFIG~CHANGED event in checkbox class. Is it possible to use (and how) this event for my task ? Any example ?...
    Thanks, Gabriel

    Hi Gabriel,
    Try uisng ON_DATA_CHECK event.
    Create a method and assign the above mentioned event. In the method have the folleoing code.
    FIELD-SYMBOLS: <l_value> TYPE ANY                           .
    Find the check box that has modified
      LOOP AT r_param->t_modified_cells INTO ls_modified_cell
        WHERE attribute EQ 'ATTRIBUTE NAME'.
        ASSIGN ls_modified_cell-r_value->* TO <l_value>           .
        CLEAR lv_index                                            .
        lv_index = ls_modified_cell-index                         .
      ENDLOOP  
    <l_value> should have the value. In your case X or space.
    You can also find index for that which is lv_index.
    So now you know the index so u know in which cell the check box is modified.
    Try that.
    Thank You,
    Gajendra.

  • Editable alv using OO ALV(newly edited row values are not updating )

    Hi friends,
    i am facing a problem. i am displaying an output alv  using OO ALV.
    i am creating a new row and validating the newly created row values and changing if it is not according to the criteria. but the newly edited values are not capturing in method
    pr_data_changed->mt_inserted_rows as it contains values only entries entered for the first time .
    i am not getting the newly edited values in it.
    please do the needful.
    Thanks and Regards,
    srinivas

    Hi!
    to rectify the problem in the Code.....
    You can Go through this program....for changed values....
    https://wiki.sdn.sap.com/wiki/x/AwBIBQ
    Regards.

  • Editable ALV using OO concept

    Hi Experts,
    We have a  requirement for an editable ALV grid where the values can be changed in the ALV and needs to be validated.
    Once the user has made an entry in the ALV grid,
    Even if the user has entered values in all the cells, It should throw error log only for the rows selected  by the user .
    Once the user has made correct entry in the field ( the row which was selected earlier and throwing error ), then the error log should be emptied and it should allow for processing.
    Please help us on this requirement, if possible with the code.
    Thanks in Advance,
    Vidya
    Edited by: vidya vidya on Oct 16, 2009 8:30 AM

    Hi,
    in the wiki (code gallery) you can find several examples.
    e.g.
    http://wiki.sdn.sap.com/wiki/display/ABAP/InteractiveEditableOOALVgridwithdynamicitab,FCATandENTERkeyeventtrigger
    Best regards.

  • Editable ALV using FM REUSE_ALV_GRID_DISPLAY_LVC.

    Hi Friends,
    I have ALV with editable field and I am using FM REUSE_ALV_GRID_DISPLAY_LVC.
    In this case I am unable to get data enter in editable column.
    I have customize PF - STATUS for ALV.
    Please guide me to resolve.
    Thanks

    hi  amit,
    check this method...it records the changes done ....
    CALL METHOD ref_grid->check_changed_data .
    hope it helps..
    regards,
    somesh
    Edited by: someshuttarwar on Nov 29, 2011 1:14 PM

  • Editable ALV Using SALV Class.

    Hi Experts,
    I need to make ALV Editable using SALV Class only.
    Thanks in Advance
    Regards,
    Ankit.
    Moderator message: please do some research before asking.
    Edited by: Thomas Zloch on Feb 25, 2011 1:47 PM

    Hi Aniket,
    This is a restriction and not provided in SALV class.
    Please have look at the earlier posts in SCN .
    Thanks.

  • Save in Editable ALV using OO

    Dear Gurus ,
    I made an ALV to be editable using OO but i  can't save .
    I read the articles here but i can't understand very well .
    Does anyone has the code for save only ....
    Thanks ..

    Hi,
    Please refer How to capture user entered values from an input enabled ALV grid?
    Regards
    Marcin

  • Issue with editable alv using  cl_gui_alv_grid

    Hello all,
    its a table update program . user can save create new entry and delete the entires . the screen should be avaiable for multiple time inputs by the user . i achived it by  method handle double click and i am refreshing the scrren and making the alv for ready for input . but user wants the screen shoukld get refreshed automatically once user clicks on save button .
    how can I achive plz advise .
    I am working on ALV by cl_gui_alv_grid , I am using the followingmethods of the class
    1)  METHODS:  handle_toolbar FOR EVENT toolbar OF cl_gui_alv_grid
                  IMPORTING e_object e_interactive.
    2)     METHODS:     handle_user_command FOR EVENT
                     user_command OF cl_gui_alv_grid
                     IMPORTING e_ucomm,
                     check_changed_data.
    3)     METHODS:      handle_double_click FOR EVENT
                      double_click  OF  cl_gui_alv_grid
                      IMPORTING e_row e_column.
    4)    METHODS: handle_data_changed
                  FOR EVENT data_changed OF cl_gui_alv_grid
                  IMPORTING er_data_changed.
    Thanks in advance .

    Hi Soumyaprakash,
    SAve is an user command . I want to have the values which are changed by the user and again the output should be ready for any actions like change the data , create new and delete any entry .
    basically  the alv output screen should be reday for inputs any number of times untill user clicks on back button .
    Thanks
    Basavaraj

  • [Editable ALV] Using deep context

    Hi,
    I am using a deep context (I have subnodes in my context that are not shown on the ALV). I use the subnodes to display list of data that I called from a button in the ALV, thus it makes sense (at least to me) to have it there in the context.
    When using subnodes, you have to be careful when you modify your context, do not use BIND_TABLE to fill your context because it will simply get rid of those subnodes. Go through all of your elements and use BIND_ELEMENT instead.
    Everything was working fine until... I tried to sort one of the columns. It actually messes up with my context by deleting these subnodes! 
    I guess it is using the BIND_TABLE method somewhere.
    Have you guys crossed this problem?
    Is there a "clever" solution to this? (a naive one would be to simply use a concatenation of all subnodes values and re-build the subnodes every so often).
    Thanks in advance.
    Best regards,
    Guillaume

    1. There is no event for this (row of column), so this will not be possible.
    2. Check report BCALV_EDIT_05.

  • Enable User Defined toolbar button on click -  editable alv grid using oops

    Hi all,
    I  have created editable alv using  oops concept.
    created 2 user defined toolbar button save and print using method toolbar
      ls_toolbar-text      = 'Print'.                         "#EC NOTEXT
        ls_toolbar-quickinfo = space.
        ls_toolbar-checked   = space.
        APPEND ls_toolbar TO e_object->mt_toolbar.
    requirement is
    initially print button should be disabled, and save enabled
    when i click save button, print button should be enabled.
    I want coding in editable alv oops concept
    kindly help
    regards
    senthil kumar

    Halo Senthil,
    You should call set_toolbar_interactive method of cl_gui_alv_grid in the on_user_command( ie the event handler for event user command) .
    method on_user_command.
    case e_ucomm.
    when 'SAVE'. or whatever your function code is .
    my_save_flag = 'X'.
    call method grid->set_toolbar_interactive.
    endmethod.
    This triggers the toolbar event of the
    cl_gui_alv_grid. Inside the eventhandler method ( ie the on_toolbar method ) you should set the toolbar.
    if my_save_flag = 'X'.
    read table e_object->mt_toolbar
    clear l_toolbar-disabled.
    modify e_object->mt_toolbar.
    endif.
    e_ucomm will not have  the function code if the save button is not in the toolbar area.
    then you can set the my_save_flag in the data_changed event handler of the Cl_gui_alv_grid.
    Regards
    Arshad

  • Search help for date field in Editable ALV

    Hello Friends,
    I am using editable alv using 'reuse_* '.
    I have used date as input field. While creating fieldcatlog also i have  declared dat as a mkpf-budat.
    But i am not getting serach help for date in output.
    Is it possible with reuse or i have to go by object oriented ?

    Hi,
    Just pass the Edit option of the fieldcatalog for those specific fields...
    fcat-edit = 'X'.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program       = sy-cprog
          i_callback_pf_status_set = 'PF_STATUS_SET'
          i_callback_user_command  = 'USER_COMMAND'    "<----  pass this
          i_callback_top_of_page   = 'TOP'
          is_layout                = it_layout
          it_fieldcat              = it_fcat
          i_default                = 'X'
          i_save                   = 'A'
          it_events                = it_event
        TABLES
          t_outtab                 = it_final
        EXCEPTIONS
          program_error            = 1
          OTHERS                   = 2.
    *&      Form  USER_COMMAND
    *       text
    *      -->R_UCOMM      text
    *      -->RS_SELFIELD  text
    FORM user_command USING r_ucomm LIKE sy-ucomm
                            rs_selfield TYPE slis_selfield.
      CASE r_ucomm.
        WHEN '&DATA_SAVE'.                "<-------check this
          PERFORM save_data.
      ENDCASE.
    ENDFORM.                    "USER_COMMAND

  • Regarding editable alv

    Hi all,
              Frnds i am working in editable alv using function modules not object oriented abap.
    i m trying to edit a Field(MATNR ) in my output list and finally update it with changed values in the DB table.
    But i m getting syntax error like
    "the work area i_final is not alligned properly
    below i m providing my code.
    <code>
    *& Report  ZEDITABLE_ALV1
    REPORT  ZEDITABLE_ALV1.
    TABLES: vbak,vbap.
    TYPE-POOLS: slis. "ALV Declarations
    data: BEGIN OF i_final occurs 0,
          vbeln like vbap-vbeln,
          posnr like vbap-posnr,
          matnr like vbap-matnr,
          erdat like vbap-erdat,
    END OF i_final.
    DATA : C_X(1) TYPE C VALUE 'X',
           C_FC_MODIFY(6) TYPE C VALUE 'MODIFY'.
    *DATA: i_final TYPE STANDARD TABLE OF T_FINAL with header line.
         i_temp type standard table of T_FINAL with header line.
    *wa_final like line of i_final.
    *DATA:i_final LIKE vbap OCCURS 0.
    *DATA:wa_final LIKE vbap.
    *ALV data declarations
    DATA: fieldcatalog TYPE slis_t_fieldcat_alv WITH HEADER LINE,
    gd_tab_group TYPE slis_t_sp_group_alv,
    gd_layout TYPE slis_layout_alv,
    gd_repid LIKE sy-repid.
    *Start-of-selection.
    START-OF-SELECTION.
    PERFORM data_retrieval.
    PERFORM build_fieldcatalog.
    PERFORM build_layout.
    PERFORM display_alv_report.
    *& Form BUILD_FIELDCATALOG
    *•     Build Fieldcatalog for ALV Report
    FORM build_fieldcatalog.
    fieldcatalog-fieldname = 'VBELN'.
    fieldcatalog-seltext_m = 'sales order'.
    fieldcatalog-col_pos = 0.
    APPEND fieldcatalog TO fieldcatalog.
    CLEAR fieldcatalog.
    fieldcatalog-fieldname = 'ERDAT'.
    fieldcatalog-seltext_m = 'date'.
    fieldcatalog-col_pos = 1.
    APPEND fieldcatalog TO fieldcatalog.
    CLEAR fieldcatalog.
    fieldcatalog-fieldname = 'MATNR'.
    fieldcatalog-seltext_m = 'material no.'.
    fieldcatalog-col_pos = 2.
    fieldcatalog-edit = 'X'.
    APPEND fieldcatalog TO fieldcatalog.
    CLEAR fieldcatalog.
    fieldcatalog-fieldname = 'POSNR'.
    fieldcatalog-seltext_m = 'line item no.'.
    fieldcatalog-col_pos = 3.
    APPEND fieldcatalog TO fieldcatalog.
    CLEAR fieldcatalog.
    fieldcatalog-FIELDNAME = 'REC_SEL'.
    fieldcatalog-NO_OUT = C_X.
    APPEND fieldcatalog TO fieldcatalog.
    CLEAR fieldcatalog.
    ENDFORM. " BUILD_FIELDCATALOG
    *& Form BUILD_LAYOUT
    *•     Build layout for ALV grid report
    FORM build_layout.
    gd_layout-no_input = 'X'.
    gd_layout-colwidth_optimize = 'X'.
    gd_layout-totals_text = 'Totals'(201).
         gd_layout-totals_only = 'X'.
         gd_layout-f2code = 'DISP'. "Sets fcode for when double
         "click(press f2)
         gd_layout-zebra = 'X'.
         gd_layout-group_change_edit = 'X'.
         gd_layout-header_text = 'helllllo'.
    ENDFORM. " BUILD_LAYOUT
    *& Form DISPLAY_ALV_REPORT
    *•     Display report using ALV grid
    FORM display_alv_report.
    gd_repid = sy-repid.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    i_callback_program = gd_repid
    i_callback_user_command = 'USER_COMMAND'
    i_callback_pf_status_set = 'GUI_STAT'
    *i_grid_title = outtext
    is_layout = gd_layout
    it_fieldcat = fieldcatalog[]
    *it_special_groups = gd_tabgroup
    *it_events = it_events
    i_save = 'X'
    *is_variant = z_template
    TABLES
    t_outtab = i_final
    EXCEPTIONS
    program_error = 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. " DISPLAY_ALV_REPORT
    **& Form DATA_RETRIEVAL
    *•     Retrieve data form EKPO table and populate itab it_ekko
    FORM data_retrieval.
    *SELECT avbeln aerdat bmatnr bposnr FROM vbak AS a
    *INNER JOIN vbap AS b ON avbeln = bvbeln
    *INTO TABLE i_final WHERE a~vbeln = b~vbeln.
    select VBELN ERDAT MATNR POSNR up to 10 rows from vbap into corresponding fields of  table i_final.
    ENDFORM. " DATA_RETRIEVAL
    *•     FORM GUI_STAT *
    *•     --> RT_EXTAB *
    FORM gui_stat USING rt_extab TYPE slis_t_extab.
    SET PF-STATUS 'MODIFY' EXCLUDING rt_extab.
    ENDFORM.
    *•     FORM USER_COMMAND *
    *•     --> U_COMM *
    *•     --> RS_SELFIELD *
    FORM user_command USING u_comm LIKE sy-ucomm
    rs_selfield TYPE slis_selfield.
    DATA:selfield TYPE slis_selfield.
    *RS_SELFIELD-REFRESH = C_X.
    CASE u_comm.
    *IF U_COMM = C_FC_MODIFY.
    WHEN 'UPDATE'.
    LOOP AT i_final. " into wa_final."into wa_final.
    *READ TABLE I_TEMP WITH KEY VBELN = I_FINAL-VBELN.
    *IF SY-SUBRC = 0.
    i_final-matnr = vbap-matnr.
    *MODIFY I_final INDEX SY-TABIX.
    *ENDIF.
    ENDLOOP.
    *ENDIF.
    MODIFY VBAP FROM TABLE i_final.
    IF SY-SUBRC = 0.
    COMMIT WORK AND WAIT.
    *MESSAGE I000 WITH SY-DBCNT
    *' Record(s) has been Updated'(020).
    ENDIF.
    *append i_final.
    *it_temp = i_final.
    *append it_temp.
    **UPDATE sflight FROM TABLE sflight_tab.
    *ENDLOOP.
    *update vbap from table i_final.
    *IF sy-subrc = 0.
    *MESSAGE s000(0) WITH 'records updated successfully'.
    *ENDIF.
    ENDCASE.
    ENDFORM.
    </code>
    Frnds plz help me in this regard.
    Thanks,
    satya

    Try something like this...ur code was not clear..i have done something u can understand.
    First check that u r not trying to update the primary key field.
    first before updating.
    Before updating select the record u r going to update from the main table.
    select single * from VBAP where <pass the key values>.
    if sy-subrc = 0.
    move the rest of the values to the table header except the key values.
    vbap-<field1> = value1.
    vbap-<field2> = value2.
    after moving the values.
    update <table>.
    if sy-subrc = 0.
    commit work.
    endif.
    data:st_vbap type vbap.
    WHEN 'UPDATE'.
    LOOP AT i_final. " into wa_final."into wa_final.
    select single * from vbap where vbeln = I_FINAL-VBELN.
    move-corresponding i_final to vbap.
    update vbap.
    if sy-subrc = 0.
    commit work.
    wk_cnt = wk_cnt + 1.
    endif.
    at last.
    *MESSAGE I000 WITH SY-DBCNT
    *' Record(s) has been Updated'(020).
    endat.
    endloop

  • Get data in editable ALV back to internal table without data_changed ev?

    Hi,
       I have an editable ALV using classes to whch I have users the option to edit directly on the screen or upload data from an excel. The event data_changed gets triggered when users edit the table on the screen.
    However when EXCEL is uploaded, I refresh the table display. So, I need a way to get the data from the ALV into a internal table to check which rows were update using the excel and save them into the db table.
    Prakash

    Hi!
    For more information, inspect programs suiting the mask "BCALVEDIT*" and the thread with header "How to make a row of ALV editable " (I know this is some more steps further from your demand but it may be useful) at URL " How to make a row of ALV editable " .
    If you want to study more BC412 "EnjoySAP Controls" may help you.
    *--Serdar

  • Issue in Editable ALV

    Hi Leads,
    I am working on Editable ALV using REUSE_ALV_GRID_DISPLAY_LVC.
    But, my requirement is I need to track the changes in Report.
    After editing the ALV report, I need to update the data base with the changed records and Need to display them as One more Report.
    Can you please suggest me any to resolve my issue?
    Thanks,
    Sandeep

    You may need to check
    http://wiki.sdn.sap.com/wiki/display/Snippets/UpdatingtheInternalTable-AfterEditinALVusingFunctionModules

  • Update out_tab data in editable ALV

    Hi,
    I am working on editable ALV using oops. I want to insert the data into database tables after user insert the data in ALV based on the application tool bar button action.
    How to refresh the data in out_tab, If user click the application tool bar button then I need to save the ALV grid data in database table.
    Please give me the valuable suggestions.
    - Rayudu

    solved my self

Maybe you are looking for

  • My computer says my songs are loaded on the ipod, but there isn't anything

    I got an iPod mini for Christmas. I followed the instructions to get everything set up on the computer (I already had iTunes). When I connect my iPod, it says all of the songs are already downloaded to my iPod and the "updates are complete". When I d

  • Existing 1811W, need to turn on wireless

    I have an existing Cisco 1811W router, running just fine, but now I need to turn on wireless. All of the web docs that I see seem to involve turning on bridging? shouldn't it be sufficient just to put the Dot11Radio0 and Dot11Radio1 interfaces into t

  • IE script error rendering DataSet.  JSP

    IE console catches the error as:       SCRIPT600: Unknown runtime error      SpryData.js, line 1269 character 4 The dataset is to be displayed in a table.  IE displays the table, but instead of data, it displays each <td> as {dataSetName::columnName}

  • How to load and unload Multiple External SWF

    hello there, i need help to figuring out how to load and also unload(removing) multiple external SWF. so here is what i;m trying to do, i want to load multiple external SWF and play it on my main SWF now i hove no problem with just loading multiple S

  • Bind variables Where X in (:B)

    Hi Is there a way to use bind variables in a where in clause (not where =) Here's my query: select * from events where BE_ID in (:BE_IDS) and BE_TIME between to_date(:StartDate, 'dd/MM/yyyy HH24:MI:SS') and to_date(:EndDate, 'dd/MM/yyyy HH24:MI:SS')