You need to sign in to do that
Don't have an account?
hy.lim1.3897974166558203E12
How to add permission to Salesforce Chatter Collaboration Group sOject?
I have communities enabled in my org and i have a class which will auto add the new registered member to a chatter group.
CollaborationGroupMember cand = new CollaborationGroupMember(CollaborationGroupId=groupId, MemberId=UserId);
try {
insert cand;
System.debug('Success insert cand >>'+ cand );
}catch(DMLException e){
System.debug('There was an error with the invite: '+e);
}
but when i execute the code it give me this error -> "Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, Entity is read-only: CollaborationGroupMember: []"
I am guessing my communities default Guest account doesnt have the right to insert new collaborationgroupmember record. is there a way to extend this permission for this guest profile?
Thanks.
CollaborationGroupMember cand = new CollaborationGroupMember(CollaborationGroupId=groupId, MemberId=UserId);
try {
insert cand;
System.debug('Success insert cand >>'+ cand );
}catch(DMLException e){
System.debug('There was an error with the invite: '+e);
}
but when i execute the code it give me this error -> "Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, Entity is read-only: CollaborationGroupMember: []"
I am guessing my communities default Guest account doesnt have the right to insert new collaborationgroupmember record. is there a way to extend this permission for this guest profile?
Thanks.
Please refer following links for more information :
https://help.salesforce.com/apex/HTViewSolution?urlname=How-to-Silently-add-users-to-Chatter-Groups&language=en_US
https://help.salesforce.com/apex/HTViewSolution?urlname=Insert-users-into-Chattergroups-using-the-Dataloader&language=en_US
https://help.salesforce.com/apex/HTViewSolution?urlname=Chatter-Profile-Based-Rollout-Pilot&language=en_US