0

I haven LWC modal popup initiated by a Quick Action. For this some Aura code is needed, but I have that working.

Upon closing (via a button on the modal popup), the underlying record page should be updated (refreshed). But it's not. The modal popup closes, but the page is not updated. This is my Javascript:

({
  modalClose : function(component, event) {
    $A.get("e.force:closeQuickAction").fire();
    $A.get('e.force:refreshView').fire();
  }
})

What am I missing here?

3
  • Do you have any component on the page? If yes, please check if the refresh event is handled
    – Samir
    Commented Mar 3, 2020 at 16:27
  • Doesn't changing the order of the events work? I would imagine if you refresh the view before closing the modal, that should work.
    – Jayant Das
    Commented Mar 3, 2020 at 20:04
  • Changing of the order of the events does not work. Commented Mar 4, 2020 at 7:14

1 Answer 1

1

You can try standard Js way

window.location.reload()
3
  • This indeed refreshes the page, but it is a bit drastic. I am looking for something more subtle. Like what you get when you are on an Account page and add a new Contact. After saving the new Contact, the Account page is refreshed, but much more inobtrustive. Do you know how to do that? Commented Mar 4, 2020 at 7:21
  • From my experience, it works smoothly not everywhere. can you check if you are seeing any error in console?
    – Samir
    Commented Mar 4, 2020 at 7:39
  • No, there are no errors in the console. Commented Mar 4, 2020 at 7:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .