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
lsatonylsatony 

Custom Object Visibility

I have a custom object that I only want 2 people to access.  Both users profiles contain many other users. 

 

Can custom object visibility be set at the user level?  If so, where?

 

Thanks!

Best Answer chosen by Admin (Salesforce Developers) 
werewolfwerewolf
Yes, you can do that using a sharing model.  Set up sharing for your object, and then you can share a given object only to its owner, to specific users, roles or groups as you see fit.

All Answers

Greg HGreg H

Object visibility cannot be defined on a user by user basis.

-greg

lsatonylsatony

Thanks Greg H.

 

If these users are added to a group, can visibility be set there?

werewolfwerewolf
Yes, you can do that using a sharing model.  Set up sharing for your object, and then you can share a given object only to its owner, to specific users, roles or groups as you see fit.
This was selected as the best answer
lsatonylsatony
awesome - thanks again werewolf!!!
Greg HGreg H

Actually, object access is defined at a profile level. If the profile doesn't have access to an object then the sharing settings will have no impact.

 

The sharing rules including organization wide defaults allow access to records not the object. This means that after the object permissions are set on the profile, the record permissions can be set by incorporating the role hierarchy and any sharing that might be needed.

 

I think your best solution is to create another profile for your two users.

-greg

werewolfwerewolf

I actually took his question to mean that he had a single row of a custom object that he wanted to expose to 2 people.  If in fact you want this entire object to be exposed to just these 2 people, than Greg is right: clone their profile, set these 2 people's profile to the new one, and give only that new profile access to that object.

 

Sharing applies to individual records within an object, but the profile trumps it -- as Greg correctly said, if your profile says you can't see it, than you can't see it period.

lsatonylsatony
ok, understood.  thanks to you both for your help!!