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

Making old opportunities read only

I would like to make any opportunities created before 8/1/09 read only. Any suggestions?

The way I handled it was to create a new record type and page layout for Locked records.


Clone the existing record type and page layout, then change all of the fields you can on the new Locked Page Layout to Read-Only. Then assign all profiles to use the Locked Page Layout with the Locked Record Type.


Once that is done you can change the Record Type on the old Opportunities to the new Locked Record Type - the sforce Connector is good for this.


Hope that helps.




This seems needlessly complex. Why not add a validation rule that says:



CreatedDate <= 8/1/09


That should do the trick, unless I'm missing something