Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Issue with Interactive ALV using SALV

Former Member
0 Likes
453

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

3 REPLIES 3
Read only

Tamas_Hoznek
Product and Topic Expert
Product and Topic Expert
0 Likes
412

You may want to edit and reformat your post using the proper tags so that the code is more readable...

Read only

0 Likes
412

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.

Read only

Tamas_Hoznek
Product and Topic Expert
Product and Topic Expert
0 Likes
412

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.