+ Start a Discussion
Ajay Kumar 583Ajay Kumar 583 

How to change the Opp stage ??

I need to Change the Opportunity Stage to “Prospecting” whenever Opportunity Amount is changes to any value.

Best Answer chosen by Ajay Kumar 583
Ajay K DubediAjay K Dubedi
Hi Ajay Kumar,

You can use the below code:

<<<<----Trigger --->>>>>

trigger HandlerTriggerOpportunity on Opportunity (before Update) {
    for(Opportunity opp : Trigger.new){
        if(opp.Amount != Trigger.oldMap.get(opp.Id).Amount){
            opp.StageName = 'Prospecting';

I hope you find the above solution helpful. If it does, please mark as Best Answer to help others too.

Ajay Dubedi