+ Start a Discussion
Namami ShuklaNamami Shukla 

Can we define a sharing rule in apex class ?

Arunkumar RArunkumar R
Yes. You can share records using apex, Please follow the below link for more info.

http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_bulk_sharing_creating_with_apex.htm
Vatsal KothariVatsal Kothari
You can also refer below link:

https://help.salesforce.com/apex/HTViewSolution?id=000002813&language=en_US (https://help.salesforce.com/apex/HTViewSolution?id=000002813&language=en_US)
Pramod_SFDCPramod_SFDC
Hi,

I believe, the below mentioned link provide you more information on this.

>> https://help.salesforce.com/apex/HTViewSolution?id=000002813&language=en_US


Regards
Pramod