Ajouter aux favorisMahi Tangnoo (iLink Digital) a publié du contenu dans Admin 201 Study Group 2021 (Question initialement posée par Mahi Tangnoo)12 mai 2023, 09:18Mahi TangnooHow to lock fields on before update and before insert and show error using triggerScenario is: On" before update" and 'before insert" of opportunityLineitem, a custom field should not get inserted and updated after saving the product details and throw an error saying that " You are not allowed to update this field ". i tried doing null check on this field and show the error in my trigger but its showing error - "sobject row does not allow errors " so i checked the field level security and it has read and write access but still this is coming So if any one could suggest any other alternative approach to achieve this use case using triggers only would be highly appreciated. Thanks,MahiAfficher plusAjouter un commentaireRédiger un commentaire...GrasItaliqueSoulignerBarréListe à pucesListe numérotéeAjouter un lienBloc de codeInsérer une imageJoindre des fichiersURL du lienAnnulerEnregistrer0/9000Répondre
Mahi TangnooHow to lock fields on before update and before insert and show error using triggerScenario is: On" before update" and 'before insert" of opportunityLineitem, a custom field should not get inserted and updated after saving the product details and throw an error saying that " You are not allowed to update this field ". i tried doing null check on this field and show the error in my trigger but its showing error - "sobject row does not allow errors " so i checked the field level security and it has read and write access but still this is coming So if any one could suggest any other alternative approach to achieve this use case using triggers only would be highly appreciated. Thanks,MahiAfficher plus