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
BhaviBhavi 

Record locking through APEX code

Hi there ,

 

I have  a problem .

I want to lock a record through APEX code.

Is  it possible ?

 

 

Please  Rply....

Thanks in advance ..

 

 

 

shillyershillyer

Take a look at Locking Statements.

 

Hope that helps,

Sati

Ron HessRon Hess

Sati, i think record locking is refering to changing the update permission on an object, not locking while updating.

 

Bhavi  , can you clarify ?

Message Edited by Ron Hess on 04-10-2009 02:05 PM
rlucasrlucas

Hi

 

We achieved this locking (changing the update permission) through calling an approval process in apex.

 

I would like to know if there is a way to lock directly in apex.

 

cheers

Richard

 

Venkat PolisettVenkat Polisett

Bhavi wrote:

Hi there ,

 

I have  a problem .

I want to lock a record through APEX code.

Is  it possible ?

 

 

Please  Rply....

Thanks in advance ..

 

 

 


 

 

If you are looking for locking records from updates without manipulating the profiles, here is an AppExchange free package that can do that.

 

Record Lock With Inline Messaging!