function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
surya kanadhipatlasurya kanadhipatla 

Issue: Community user(profile) not able insert the case team member using trigger(getting exception)

Hi All,
We have implemented a trigger to associate case team memebers to a case created via community user.
This trigger works fine for internal users but when users with community user profile creates a case its throws following error:
Op:Insert|Type:CaseTeamMember|Rows:1
System.DmlException: Insert failed. First exception on row 0; first error: OP_WITH_INVALID_USER_TYPE_EXCEPTION, Operation not valid for this user type: []

I have verified community user profile does have read/write access to case object and able to create the cases as well.
Even tried without sharing key word still exception.Observed the exception when caseteammember is inserted.
If i comment out the insert caseteammemebr line in trigger helper class no exception and case was created without case team members...

Any Help will be appreaciated...