You need to sign in to do that
Don't have an account?
Ram_SF14
Trigger Context Variables
Hi All
I am trying to auto populate field from Obj B to Obj A. I have written a trigger, which is working fine. But I only want to work for before insert and before Update. Can you anyone please help with the correct context variable that needs to used ?
I have used the following for before update it is working fine but not working for insert. Please help
if(trigger.isBefore && trigger.isUpdate){
OpportunityTriggerHandler.autoPoplate_User(trigger.new);
}
I am trying to auto populate field from Obj B to Obj A. I have written a trigger, which is working fine. But I only want to work for before insert and before Update. Can you anyone please help with the correct context variable that needs to used ?
I have used the following for before update it is working fine but not working for insert. Please help
if(trigger.isBefore && trigger.isUpdate){
OpportunityTriggerHandler.autoPoplate_User(trigger.new);
}
if( trigger.isBefore){
if( trigger.isInsert || trigger.isUpdate){
OpportunityTriggerHandler.autoPoplate(trigger.new);
} }
The above is working