Skip to Content
author's profile photo Former Member
Former Member

ALV refresh after saving

Hello!

I thought with the previous post's about ALV refreshing i could do it myself...it seems i have some isues that i don't understand why it doesn't work!

So my ALV as some editable fields, when i make changes in this fields and then click the save button it saves me the changes to a Z table. On every load of the ALV there are some fields that are filled with data from de Z table x data from standard table. When i save i want this to appen without having to go the previous screen and then go to the next screen.

In the statement When '&DATA_SAVED' i have some code that saves my data do the Z table. Iv'e tryed to call the method refresh_table_display and check_changed_data at the begining of the Where statement and after the last line of code in this statement, after the insert in the Z table, and it didn't worked...

So...any help would be nice!

Cumps,

RT

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Apr 09, 2008 at 12:20 PM

    Hi,

    After the code you have written in &data_save

    write

    selfield-refresh = 'X'.

    <REMOVED BY MODERATOR>

    Regards,

    Talwinder

    Edited by: Alvaro Tejada Galindo on Apr 9, 2008 5:48 PM

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Ok, i managed to solve the problem.

      I added the line that you said, butt it was missing some other stuff...

      so the scheme i did was the following:

       
      data:ref    TYPE REF TO cl_gui_alv_grid.
      ...
      when '&data_save':
      
      CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
              IMPORTING
                e_grid = ref.
      
      CALL METHOD ref1->check_changed_data.
      
      ls_selfield-value = ' '.
      ls_selfield-refresh =  'X'.
      ls_selfield-col_stable = '3'.
      ls_selfield-row_stable = '1'.
      
      loop at itab.
      ....
      endloop.
      
      perform data_retrieval.
      CALL METHOD ref1->refresh_table_display.
      

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.