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

Help me on account share trigger
trigger AccountTrigger on Account (after insert, after update) {
for(Account acc : Trigger.new){
accountShare as1=[SELECT id, AccountaccessLevel,RowCause,userorgroupid from accountShare where accountid=:acc.id and rowcause='Rule'];
AccountShare accountShare = new AccountShare();
accountshare.RowCause='Rule';
// userorgroupid =''
accountShare.AccountAccessLevel = 'All';
update accountshare;
}
}
What is the actual issue in this?.. can you expline me for further debug
Thanks
karthik
Row Casuse can be Owner, Manual etc