You need to sign in to do that
Don't have an account?

Change case owner problem in before insert trigger on case
Hi All
I have written a trigger as below
trigger testChangeOwnerTrigger on Case (before insert) { for(Case newCase : Trigger.New){ newCase.OwnerId ='005R0000000IufqIAC'; } }
Here the 'created use'r and 'new owner user' has the same profile.
This trigger is working correctly when I create case with System Administrator profile user, but when create case with other profile user then it throw an error "Insufficient Privileges You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary. Click here to return to the previous page "
I checked the profile & it has all data modification permissions.
Any idea?
Thanks
Hello,
Did you solve the problem? I met the same error.
Please post how you solve it.
Thanks.
I am facing kind of a similar problem.
I have a profile : AFA Help Desk with following features :
1. Manage Cases - check
2. Transfer cases - check
3. Sharing rule based on case record type that grants Read/Write access to the concerned role.
Use Case : AFA Help Desk profile user updates a case with a particular status , based on status value , case owner is changed to a different profile.
Error :
I have tried to enable the option "Transfer Case" on the profile of that user and it worked for me. Maybe you can try the same.