‎2009 Aug 05 1:17 PM
Hi Champs,
In my requirement I have to add a refresh button functionality in the ALV.
IF there are errors in the file
Then CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
and display errors
ELSE.
WRITE: No error in the file.
ENDIF.
Now in one scenario I selected the file and desplayed the error using CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY' but then I rectified the error manually and pressed the refresh button.
Ideally since there are no errors then it should write the message that No error in the file.
But I have seen that though it is going through this else condition but at last it is again giving the same error list, though the errors were rectified.
To my dismay if i use CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' it works fine.
Want to know do we need to refresh any parameter after using CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'.
If yes then what is it?
Cheers,
Nishant
‎2009 Aug 05 5:21 PM
Hello Nishant,
function module 'REUSE_ALV_GRID_DISPLAY' only displayes the tables without caring what all data it contains so
after correcting the file your internal table still contain the old rows which you need to clear.
So, once you correct the file again check if file has any errors. if not then clear the internal table and raise no errors message.
Hope this helps!
Thanks,
Augustin.