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
Shahil Khan 1Shahil Khan 1 

Prevent users for a certain profile from manually creating Lead Records

I want to restrict users with a specific profile "SDR" to not be able to create Lead records manually. Can someone please share a Validation rule for this request.
Steven NsubugaSteven Nsubuga
Why not use the profile and not assign it Create permission on the Lead object?

But if you really want a validation rule then here you go:
 CreatedBy.ProfileId ="xxxxxxx" 

 
Raj VakatiRaj Vakati
Try this 
 
AND( 
  ISNEW() , 
  $Profile.Name =="SDR"
)

 
Raj VakatiRaj Vakati
AND(
ISNEW(),
 Not(IsConverted),
 $Profile.Name =='System Administrator')

This is correct please use