Category Archives : Lightning web components

LWC in Flow – How to Refresh Screen Values?

On October 9, 2025, Posted by , In Lightning web components, With Comments Off on LWC in Flow – How to Refresh Screen Values?

Question: I’m using a Lightning Web Component (LWC) inside a Flow screen that contains multiple input fields, where one field is always visible and others are conditionally shown based on selections from earlier Flow screens. To preserve user input when moving between “Next” and “Previous” screens, I enabled the Flow…

Fix LWC Datatable Filtering with Infinite Scroll

On September 10, 2025, Posted by , In Lightning web components, With Comments Off on Fix LWC Datatable Filtering with Infinite Scroll

Question I am building a Lightning Web Component (LWC) that displays data in a custom datatable with infinite scrolling enabled. The table initially loads five records, and then fetches more in batches when the onloadmore event is triggered. This part works fine. The problem occurs when I apply a filter….

Can You Use Built-in Lightning Components in Aura?

On July 2, 2025, Posted by , In Lightning web components,Salesforce, By ,, , With Comments Off on Can You Use Built-in Lightning Components in Aura?

Question I have a form where users need to select 3 out of 5 products, similar to the Order > Add Product modal. I was wondering if there is a way to bring that functionality into my Aura component while applying a filter to display only the products I want…

Why Can’t I Add a Property to the Apex Result Array?

On June 28, 2025, Posted by , In Apex,Lightning web components,Salesforce, By ,,, , With Comments Off on Why Can’t I Add a Property to the Apex Result Array?

Question I’m trying to add a new property called showDeleteButton to each object in the result array returned from an Apex call. However, when I include the result.forEach line, the code after it does not execute. It seems like the mutation is not working as expected, and the array remains…

Why Isn’t My URL Button Working on Mobile?

On June 24, 2025, Posted by , In Apex,Lightning web components,Salesforce, By ,,, , With Comments Off on Why Isn’t My URL Button Working on Mobile?

Question I have a Lightning Web Component (LWC) that is URL Addressable and defined as follows: The component retrieves the record ID from the URL parameters using CurrentPageReference: The init() method makes an Apex call using the oppId. I created a custom URL button on the Opportunity record page with…

Why Isn’t My LWC Refreshing on an LWR Page?

On June 2, 2025, Posted by , In Lightning web components,Salesforce, By ,, , With Comments Off on Why Isn’t My LWC Refreshing on an LWR Page?

Question I am trying to refresh my Lightning Web Component (LWC) on an LWR (Lightning Web Runtime) Page in Experience Cloud after a record save. I have tried using refreshApex and RefreshEvent, but neither approach updates the component as expected. The toast notification appears, and the onClose method executes, yet…

Why Omniscript Not Showing on Experience Cloud?

On June 2, 2025, Posted by , In Lightning web components,Salesforce, By ,,, , With Comments Off on Why Omniscript Not Showing on Experience Cloud?

Question I have added an Omniscript to an Experience Cloud page, but it is not rendering. The Omniscript contains a Lightning Web Component (LWC), and when I place it on the site, nothing appears on the page. Here is my LWC code:HTML JavaScript XML (Meta Configuration) What could be the…

Does a Permission Set in @TestSetup get removed after Test.stopTest()?

On May 20, 2025, Posted by , In Apex,Lightning web components, By ,, , With Comments Off on Does a Permission Set in @TestSetup get removed after Test.stopTest()?

Question If we create a Permission Set inside a @TestSetup method in an Apex test class, will it be automatically removed after Test.stopTest(), similar to how standard or custom object records are deleted at the end of a test execution? For example, consider the following code: After Test.stopTest(), will this…

Why is window.open() in Salesforce LWC Throwing a Security Error?

On May 18, 2025, Posted by , In Lightning web components,Salesforce, By ,, , With Comments Off on Why is window.open() in Salesforce LWC Throwing a Security Error?

Question I have been using window.open() in one of my Salesforce LWC components for years without any issues. This function is used to open an external webpage (not hosted on Salesforce). Recently, I started encountering the following error only when triggering window.open() while the previous popup remains open: In my…