Sunday, September 7, 2014

Display standard button for specific profile without controller in List View

Visual Force Code:


<apex:page standardController="Order__c" tabstyle="Order__c">
 <apex:outputpanel id="panel" rendered="{!$Profile.name != 'System Administrator'}">
     <style>
         input.btn[name="new"] {
                display: none;
         }
     </style>
 </apex:outputpanel>
<div id="lblProfileId"></div>
 <apex:listViews type="Order__c"/>

</apex:page>

No comments: