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
larryg23larryg23 

Clone Opportunity Revision

I am trying to create a button that will clone the current opportunity, add 1 to a "counter" field and rename the opportunity.  What this will be used for is revisions of the current opportunity.  So if the current opportunity is named TES-0001 and someone hits the custom button (called revision) it will add 1 to the counter field and name the opportunity TES-0001 Rev(counter field).  SO if it was the first revision the name would be TES-0001 Rev1 and so on.  I have tried to use a javascript button to do this, but i keep getting "undefined" errors.  I don't want someone to write it for me, but I would appreciate a point in the right direction with the coding. 

 

Any response would be greatly appreciated!

 

Thank you for your time.