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
Samrat ShahSamrat Shah 

cutom button

I have a Custom object where we have Visual force page button,
The requirement is:
The Object Tab is enabled for Portal Users, If  object record created/Owned by Portal user then only they should be able to access this Visual force page button. If the record is created/Owned by any other users this button should throw error or should be disabled for these portal users. 

Portal User have view all access to this object. Poratl user can only edit that they own/create. The visual force page button does not have any security. I want to create a rule or button in this object to restrict access to portal users if the record is created by someone else beside them. 

How can I achieve this requirement and what will be the syntax.
siddarth rajsiddarth raj
I am not sure How could this help you..... But my Idea would be

In a controller have boolean flag to render/disable the button you wanted, and determing it by finding createdby use is belongs to portal users or not.