+ Start a Discussion
MinouMinou 

Update field using button with JavaScript

We have created a custom object called Candidate Tracker and have created workflows to update various fields and create tasks but I am having problems with one field update. I would greatly appreciate any help that can be offered as  I am new to Salesforce and do not have much knowledge about writing JavaScript but I have managed to find some (code) out on the discussion boards that has been a great help.  So here is what I am looking for:

 

In the Candidate Tracker, I have created a button that when clicked opens an email template so we can forward a resume to someone.  The button is called "Submit Resume" and this is what the code looks like:

 

location.replace('/email/author/emailauthor.jsp?retURL=/{!Candidate_Tracker__c.Id}&p3_lkid={!Candidate_Tracker__c.Id}&p2_lkid={!Candidate_Tracker__c.Manager_NameId__c}&p6= Company Name- Resume&template_id=00X50000001RiCn&p5=');

 

Now I would like to also add an action that will update a Picklist Value in a field called " Company  Stage" from "Company Received Permission to Submit Resume" to  "Company Submitted  to Client". Can anyone offer me the JavaScript I will need to execute this action?

 

Please help!

Thanks in advance everyone!