Apex Class
public class AccountTriggerClass {
public static void BeforeInsert(List<Account> newList){
for(Account acc : newList){
acc.Description ='This account is for demo purpose';
}
}
}
Apex Trigger
trigger AccountTrigger on Account (before insert) {
AccountTriggerClass.BeforeInsert(Trigger.New);
}
Image