cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

UI does not refresh on delete of instance through custom action button

Shahab2
Explorer
1,367

Hi Everyone, 

I am currently on S4HANA 2020 on premise system, and we have built a managed RAP application. As per requirement, on click of action button, I am deleting the already existing instance after update and moving it another table. 

For deletion, I am using the below commands for delete of instance. But after deletion, the page doesn't refresh, and only after pressing Go button, I can see the refreshed list with removed instance. 

Shahab2_0-1719129961427.png

Please need inputs here so I refresh my page without user interference of click of GO button. 

Andre_Fischer

Side effects won't work here as I am on S4HANA 2020. 

 

 

Thanks,

 

 

 

Accepted Solutions (1)

Accepted Solutions (1)

MioYasutake
SAP Champion
SAP Champion

@Shahab2 

Can you try adding side effect annotations in the local annotation file? I think it works for S/4HANA 2022 as well. Please see the sections below in the document.

  • Side effect after executing an action
  • Refresh the navigation target
Shahab2
Explorer

Thanks Mio. Solution worked for me. 

Shahab2
Explorer
0 Likes

Hi Mio, I was able to refresh the list but now have a new issue. Here is the case - I am deleting an instance based on condition when user click action button. And have used side effects in annotation file to refresh the list. The list is refreshed successfully. But problem occurs when I open the object page and come back and try to use action button. It deletes the instance but it also throws an error message. It is trying to find the deleted instance. PFA.

Shahab2_0-1721122887830.png

It is trying to put GET call on the deleted item here. 

Br,

Shahab

zsofiafodor
Newcomer
0 Likes

Hi @Shahab2

Did you manage to solve your second issue with the error message? I'm facing a similar issue and would like to know if you found a solution.

Thanks

rfreitas87
Explorer
0 Likes
hi @Shahab2, did you solve your issue? im on newest version and im facing the same problem, after deltingh trough custom action system is trying to perform the GET and i have error

Answers (0)