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
Arshad ShaikhArshad Shaikh 

How to move data from one field to another field without saving

if u enter some value in field automatically other field gets populated with same copy.
salesforce mesalesforce me
Hi Arshad gothrough once this...
 
trigger conAccountName on Contact (before insert) {
 string ids; for(contact con : trigger.new)

ids = con.accountid; 
}
 list<account> accountlist = new list<Account>([select id, name from account where id =:ids]); string accName; 
for(Account a : l){ accName = a.name; }
 for
(contact c : trigger.new)
{
 c.lastName = accName; } 
}