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
Prabhat Singh 56Prabhat Singh 56 

How to customize to set default value of Lookup field(pre - populate) ?

Hello Team,

I add one customization filed on the Opportuntiy Object which Data type is Lookup (User). And when user create a new opportunity i want this filed has default vaule as same opportunity owner.

I try to use Processing builder or trigger to fulfill this requirement but the result is not what I expected , is there any customiztion way to fulfill this requirement ?

Thanks
Prabhat
Rohit SharmaGRohit SharmaG
Hi, Please write a trigger on opportunity with before insert event and assign the current user to Lookup field.