‎2011 Apr 15 11:02 PM
Hi friends,
I have an issue with an Interactive ALV report using SALV class. The program needs to display an alv report after seelction-criteria is entered. User should be able to use 'select all' and 'deselect all' and refresh the list. Button click on primary alv should display another alv. I developed a program using SALV class. The report works fine except in one case...'Selectall' button works fine first time in primary alv list. Probelm comes after 2nd list is displayed and control goes to primary screen on BACK button click.This time the 'select all' button click on primary list displays the same 2nd ALV list instead of primary list. It happens same with 'Deselect all' too.
I am thinking its an issue wiht re-initializing...not sure. Please advice what could be wrong.
Below is the code for the SELECT ALL. I am also copying the entire code .
<removed by moderator>
Moderator message: please post only relevant code parts, your post must be less than 5000 characters to preserve formatting.
Edited by: Thomas Zloch on Apr 16, 2011 9:32 PM
‎2011 Apr 16 12:16 AM
You may want to edit and reformat your post using the proper tags so that the code is more readable...
‎2011 Apr 18 6:01 PM
Here is the subroutine where actually the code doesn't work 2nd time when we come back from secondary screen.
Form select_all.
LOOP AT i_tab ASSIGNING <lf_data>.
IF <lf_data>-check IS INITIAL.
<lf_data>-check = 'X'.
ENDIF.
ENDLOOP.
i_salvtable->refresh( ). -
> This code calls the secondary screen instead of primary screen
End form .
It could be an issue with screen control too.. please advice.
METHOD on_user_command.
WHEN 'OINV'.
Show Outstanding Invoices
PERFORM outstand_inv. -
> fill alv tabel for secondary list
Call screen 100.----> displays secondary list
ENDMETHOD.
‎2011 Apr 18 6:42 PM
Can't really say much without seeing the rest of the code, but as a wild guess, try this:
Instead of i_salvtable->refresh( ), use i_salvtable->refresh( refresh_mode = if_salv_c_refresh=>full ).
See if this makes a difference.