4 votes
Accepted

TypeError: Cannot read properties of undefined (reading 'DOB') in for loop

When initializing your for loop to iterate through an array using its length and starting at 0 you need to use < rather than <=. In your code you have: for(let i=0 ; i <= this....
user avatar
  • 2,050
2 votes
Accepted

Hide/Show columns of lightning-datatable in Lightning Web Components

The only thing you need to do is removing the desired element from the columns array, or use the original set if you want it back. <template> <lightning-input type="toggle" ...
user avatar
  • 61
2 votes

How to use Cobertura and JUnit reporters with LWC Jest?

I found out via the official Jest documentation that you can also overwrite or extend the configuration (Configuring Jest). If you do this as follows, you can also use Cobertura, JUnit or even other ...
user avatar
2 votes

How to get selected rows from multiple tables with one button in LWC?

JavaScript has a number of ways to do this. Here's one example: let eachTableSelections = [...this.template.querySelector('lightning-datatable')] .map(table => table.getSelectedRows()); let ...
user avatar
  • 429k
1 vote

Can we insert an image in lwc cmp without using static resource?

Yes, there are a few mechanisms. One common mechanism is using Asset Files (ContentAsset), which is stored like a File (ContentDocument/ContentVersion), but is deployable/packageable. Here is an ...
user avatar
  • 1,195
1 vote

Update Record field through LWC button click

You don't need both: @wire(getCheckedStatus)acStatus; and getCheckedStatus({selectedAccId: this.recordId}) Choose one. Also, const allValid = [...this.template.querySelectorAll('lightning-input')] ...
user avatar
  • 429k
1 vote

How to and retrieve , display the key and value of map<string,id> in LWC which is returning from an apex wrapper class

Use below logic in LWC JS file: getPageResoursesFalse() { pageResourcesFalse({cardName:this.tile}) .then((result)=>{ let resultData = [...result]; resultData.forEach((...
user avatar
  • 531
1 vote

LWC Quick Action Error with Record EDIT Form for Lookup Field after Summer 22 Update

We have an ongoing investigation for this behavior numbered #W-11115198 logged with the concerned salesforce product team. It was reported by several other customers too and is being worked on with ...
user avatar
  • 2,421

Only top scored, non community-wiki answers of a minimum length are eligible