+ Start a Discussion

How to hide a section in a standard pagelayout based on the user

Iam looking a a way to hide a particular section in the standard layout of Account object. What is the better way to do this? If you have any thoughts, please let me know.
You can create a pagelayout specific to this user profile and assign that to this user so when he opens the record - the sections relevant to him re the ones he/she sees: http://help.salesforce.com/HTViewHelpDoc?id=customize_layoutassign.htm&language=en_US
Thanks Sonam. Iam aware of that. I don't want to create a seperate profile for these users just to hide a section in one Layout. Iam looking for a dynamic way of hiding the section based on the user who logged in.
In that case you would have to go with overrriding the current page with the visualforce page so that you can control the UI based on the user viewing it.

Check the following link which talks about a similar issue - it has sample code as well:
Thanks Sonam. Yeah, I did looked at that post before, but in my case I have a visual force component embeded in a section in a standard page layout and I want to hide that section based on the User. Field sets wont work in this case.  Anyways thanks for your help.
Venkata Shiva Koushik RachapudiVenkata Shiva Koushik Rachapudi
Hello @anusfdc123.
i am facing this same problem and would want to know how you had this fix. i have a visualforce component that needs to be visible to the pagelayout but not all users. permission set is throwing a insufficinet privileges error messsage. and i dont want that to be shown to the users