+ Start a Discussion
SarahSarah 

Getting an error when switching the view in Android and iOS

An error is getting when users attempt to switch view via dropdown only on mobile devices. It is working fine in desktop. How to fix this issue? 

Thanks in advance. 
SwethaSwetha (Salesforce Developers) 
HI Tency,
Can you share the error message? Thx
SarahSarah
Hi Swetha, 
In Android, it is showing " A component error has occurred "
[Cannot read properties of null (reading 'setCustomValidity') ]

In iOS " This page has an error. You might just need to refresh it"

Thanks
SwethaSwetha (Salesforce Developers) 
HI Tency,
Is there a minimal code snippet that you can provide minus the dependencies so I can replicate this behavior on my org and mobile devices?

Checked related scenarios for this error message

https://trailblazer.salesforce.com/issues_view?id=a1p3A0000003gCEQAY&title=lightning-recordform-exception-cannot-read-property-setcustomvalidity-of-null-while-re-populating-a-form-with-error-status-of-picklist-field

https://salesforce.stackexchange.com/questions/340730/lwcgetting-error-while-setting-custom-validity-error-messages-in-lwc-form-ca

https://salesforce.stackexchange.com/questions/229878/how-to-set-setcustomvalidity-on-lightninginput

Thanks
poged herrypoged herry
KFC Great Britain Experience Survey allows participants to share their valuable feedback so that they can serve better. YourKFC Survey
Anya GardnerAnya Gardner
Rohtas Digital is a leading SEO link building (https://rohtasdigital.com/link-building-services/) company that provides the best link building service in accordance with search engine trends.