If a user has insufficient privileges to view an object, any Visualforce page that uses a controller to render that object will be inaccessible. To avoid this type error, we should ensure that our Visualforce components will only render if a user has access to the object associated with the controller.
You can check for the accessibility of an object this way:
In the same way you can check either the current user has the permission to create,update,delete etc. any object with the following methods :
Suppose you have added a “Delete” button to delete the account records in your VF page,but an user with custom profile did not have permission to delete the account records. So how you hide that button for a particular user in same VF page. You need to use the above method to hide that button :