1.Click “Setup | Create | Objects”.2.Select the custom object. (In this case, the “Test” Custom object.)
3.Click New in the Apex Sharing Reasons related list. ..
4.Enter a label for the Apex sharing reason.
5.Enter a name for the Apex sharing reason.
6.Click Save.