Wednesday, June 3, 2015

Salesforce Button: Change status of Lead Status field.

Take an example a company uses Salesforce CRM in their organization. A user has come to you with request that he wants a button on Lead record detail page to change Lead Status field to “Closed – Not Converted”. How can this be done using button?
The system administrator needs to create button.

Navigation: Setup > Customize > Leads > Buttons, Links and Actions

New Button or Link

Enter the details
Label: Change Lead Status to Closed – Not Converted.
Name: Auto populated
Description: Change Lead Status to Closed – Not Converted
Display Type: Detail Page Button
Behavior: Execute JavaScript
Content Source: OnClick JavaScript

Code
{!REQUIRESCRIPT("/soap/ajax/27.0/connection.js")}
var objLead = new sforce.SObject('Lead');
objLead.Id = '{!Lead.Id }';
objLead.Status = 'Closed - Not Converted';
var result = sforce.connection.update([objLead]);
if(result[0].success=='true'){
alert('The Lead was Updated Successfully');
location.reload(true);}

Click Syntax for errors and save.

When you click save following page is displayed notifying us to add the button to the page layout.

Add Change Lead Status to Closed – Not Converted button to the page layout.

Lead detail page. Lead Status: Working – Contacted. Now I want to change the status to Closed – Not Converted. Click the button.

The Lead was updated successfully.

Lead Status changed to Closed – Not Converted.


108 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. Thank you for having taken your time to provide us with your valuable information relating to your stay with us.we are sincerely concerned.., Most importantly, you Keepit the major...
    hadoop Training in Chennai

    ReplyDelete
  3. this blog says some thing informative mission it is really good thanks for sharing this information , it is really nice too.




    informatica training in chennai

    ReplyDelete
  4. Great work,provided information was really so nice,thanks for giving that post and the more skills to develop after refer that post.our giving articles really impressed for me,because of all information so nice.
    ccna training

    ReplyDelete
  5. Such as very good information,
    Thank goodness someone is promoting quality content.these information was more effective content. I can easily understand all given information.
    sas

    ReplyDelete
  6. This is really a great post. Thank you for taking time to provide us some of the useful and exclusive information with us. Keep on blogging!!

    Cloud Computing Training in Chennai

    ReplyDelete
  7. Wow amazing i saw the article with execution models you had posted. It was such informative. Really its a wonderful article. Thank you for sharing and please keep update like this type of article because i want to learn more relevant to this topic.

    SAP Training in Chennai

    ReplyDelete
  8. Brilliant post thanks for cool and informative post i really happy to read this post..:) Web Official Blog

    ReplyDelete
  9. Really very nice blog information for this one and more technical skills are improve,i like that kind of post.



    SAP training in Chennai

    ReplyDelete

  10. That is very interesting; you are a very skilled blogger. I have shared your website in my social networks!


    SAP training in Chennai

    ReplyDelete

  11. Great Article I love to read your articles because your writing style is too good, its is very very helpful for all of us and I never get bored while reading your article because it becomes more and more interesting from the starting lines until the end. So Thank you for sharing a COOL Meaningful stuff with us Keep it up..!

    SAP training in Chennai

    ReplyDelete
  12. Superb explanation & it's too clear to understand the concept as well, keep sharing admin with some updated information with right examples.Keep update more posts.


    SEO Company in Chennai

    ReplyDelete
  13. Joshua vs Klitschko is a professional boxing match to be contested between Anthony Joshua vs Klitschko Live. Joshua vs Klitschko Live Stream is a professional boxing match to be contested between Joshua vs Klitschko Fight. Watch Joshua vs Klitschko event will take place on 29 April 2017 at Wembley Stadium in London, England, with Joshua's IBF and the vacant WBA (Super) and IBO heavyweight titles on the line. The Klitschko vs Joshua Ukrainian has not fought since then and at 41-years-old, many are expecting him to lose back-to-back fights for the first time in his career.

    ReplyDelete
  14. "We're all very relieved to hear that everyone is safe and that the suspects were caught,'' Taco Bell Corp. spokesman Rob Poetsch said in an email to The Associated Press.

    Dixon will start on the pole for the third time at the Indianapolis 500 on Sunday. The four-time series champion won the Indy 500 from the pole in 2008.

    Franchitti is a three-time Indianapolis 500 winner who retired following a massive crash at the 2013 IndyCar race in Houston. He suffered a broken back and right ankle and a concussion in the crash.

    ReplyDelete
  15. The US Open: You need to know the US Open Golf Championship will be the 117th US Open Golf 2017, US Open Schedule to be played June 15–18 at Erin Hills in Erin, Wisconsin, northwest of Milwaukee. For so many years, US Open Live everyone knew what to expect US Open Golf Live and US Open Live Stream. For the second time in three years, the 2017 US Open Golf is headed to a course that has never hosted a major. It will be the first US Golf Open in 25 years that doesn't have the names Tiger Woods or Phil Mickelson among the starting times US Golf Open 2017. Woods is missing all the majors for the second straight year because of a fourth back surgery, which was a month before his DUI arrest in Florida 2017 US Open Golf Live. Mickelson US Open Golf Live Stream, with a record six runner-up finishes in the only major he hasn't won, said he plans to skip because his daughter's high school graduation is the same day as the opening round. US Open TV Coverage and US Open 2017 Results


    US Open Golf 2017
    US Open Golf 2017 Live
    US Golf Open 2017
    US Open Golf 2017 Live Stream

    ReplyDelete
  16. Floyd Mayweather vs Conor McGregor fight details, date, weight and more 20 Here’s everything you need to know about the Mayweather vs. McGregor boxing match

    Mcgregor vs Mayweather

    Mayweather vs McGregor

    Mcgregor Mayweather

    Mayweather McGregor

    ReplyDelete


  17. You have made nice post sir, I will bookmark this page, an obligation of appreciation is all together for information. I truly esteem your own particular position and I will make a point to return here soon.and feel free visit my blog as well.
    mayweather vs mcgregor, mcgregor vs mayweather, mayweather vs mcgregor, mayweather vs mcgregor live

    ReplyDelete




  18. Mayweather versus McGregor:How to Watch Mayweather versus McGregor? Right when is Mayweather versus McGregor? What Time Mayweather versus McGrego? What Channel Mayweather versus McGregor? Mayweather versus McGregor Fight Date,Fight Time,Fight Card,Which TV,Showtime PPV,Stream Live,Update Online,Mayweather versus McGregor PPV Price,Mayweather versus McGregor Tickets Price,What Venue is happening Mayweather versus McGregor?
    mayweather vs mcgregor , mayweather vs mcgregor , broner vs garcia , garcia vs broner





    ReplyDelete
  19. Mayweather vs Mcgregor game on Floyd Mayweather Jr vs Conor McGregor on Saturday, August 26 2017.Time are going day by day every step every moment are count for Mayweather vs Mcgregor .
    Mayweather vs Mcgregor PPV
    mcgregor vs mayweather ppv
    Mayweather vs Mcgregor

    ReplyDelete
  20. Very interesting and informative blog., you explained step by step actions clearly. Thank you for sharing. Software Testing Training in Chennai | Selenium Training in Chennai | ALM Training in Chennai

    ReplyDelete
  21. Very interesting blog which helps me to get the in depth knowledge about the technology, Thanks for sharing such a nice blog.. Best Android Training in Chennai | Best IOS Training in Chennai | Best Java Training in Chennai

    ReplyDelete
  22. Whether you're looking for a Secret Santa Present for your friend, a Stocking Filler for the little one or a Christmas present for loved ones, Prezzybox have a great range of gift ideas for all! You will find the best Christmas gifts right here!

    Christmas Gifts

    Christmas 2017

    Christmas Gifts for Men

    Christmas Gifts for Women

    Christmas Gifts for Girls

    Christmas Gifts for Boys

    Christmas Gifts for kids

    Christmas Gifts for Teens

    Christmas Gifts for Coworkers

    Christmas Gifts for Mom

    Christmas Gifts for Couples

    Christmas Gifts for Teachers

    Christmas Gifts for Dogs

    ReplyDelete
  23. Lead Abatement and Lead Hazard Standards. There are numerous state, federal and industrial standards for lead exposure, lead abatement, testing for lead and removing it. This article addresses the most commonly cited standards on lead. An Introduction to lead exposure

    ReplyDelete
  24. Great article, Thanks for sharing the information with us please do keep updating on...
    Best Online Software Training Institute | Salesforce.com Integration Training

    ReplyDelete
  25. Watch Free indy 500 Live Stream watch online, https://www.derbykentucky.com/watch-indy-500-live/ indy 500 is an automobile race held annually at Indianapolis Motor Speedway in Speedway, indy 500 start time, Indy 500 schedule, indy 500 winners 2018

    ReplyDelete
  26. The 147th edition of the British Open begins July 19 at the Carnoustie Race Championship in Angus, Scotland.Defending champion Jordan Spieth leads the pack as he tries to put Claret Jug up for his fourth major victory in his career.MORE: Chances of winning the British Open 2018

    British Open 2018
    British Open
    The British Open 2018
    British Open Golf
    British Open 2018 Live
    2018 British Open

    British Open 2018
    British Open
    2018 British Open
    British Open Golf 2018
    British Open live
    2018 British Open Golf

    ReplyDelete
  27. For complete coverage of UFC Fight Night 136, have a peek at the UFC Events section of the website.

    The Blue Corner is MMAjunkie's website area. We don't take it too seriously, and neither should you. If you come whining to us that something you read is not hard-hitting news, hope to have the prior sentence repeated in ALL CAPS.
    UFC 229 Live Stream

    ReplyDelete
  28. For complete coverage of UFC Fight Night 136, take a look at the UFC Events section of the website.

    The Blue Corner is MMAjunkie's website place. We don't take it too seriously, and neither should you. Should you come whining to us that something that you just read isn't hard-hitting news, expect to have the former sentence replicated in ALL CAPS.
    UFC 229 Live Stream Online

    ReplyDelete
  29. The 2018 Country Music Association has announced that the 52nd annual CMA Awards Live Stream. Country Music Association it's called CMA. annual music awards program on network broadcast here

    ReplyDelete
  30. Really awesome blog. Your blog is really useful for me
    Regards,
    PHP Training Institute in Chennai

    ReplyDelete
  31. Thank you so much for posting this. I really appreciate your work. Keep it up. Great work!Best software training company with placement in Hyderabad

    ReplyDelete
  32. The Week Vegas Goes Country just got a whole lot bigger. The Academy of Country Music has announced a slew of incredible new talent taking the stage at the 54th Annual ACM Awards. ACM Awards 2019 Live via live ACM Awards 2019 Live Streamor The power-packed lineup will include incredible live performances from Dierks Bentley, Brooks & Dunn, Brandi Carlile, Eric Church, Kelly Clarkson, Luke Combs, Dan + Shay, Florida Georgia Line and Ashley McBryde. ACM Awards 2019 Live Streaming Tickets for the 2019 ACM Awards are available at axs.com. For more information about the big show and all ACM events, including ACM Party for A Cause. ACM Awards 2019 Live Stream Hosted by Reba McEntire, this year’s ACM Awards will air live on CBS from Las Vegas’ MGM Grand Garden Arena April 7.ACM Awards 2019 Live 54th Annual ACM Awards, Ashley McBryde, Brandi Carlile, Brooks and Dunn, Dan + Shay, Dierks Bentley, Eric Church, Florida Georgia Line, Kelly Clarkson, Luke Combs.

    ReplyDelete
  33. This is an awesome post.Really very informative and creative contents. These concept is a good way to enhance the knowledge.I like it and help me to development very well.Thank you for this brief explanation and very nice information.Well, got a good knowledge.
    Spoken English Class in Coimbatore
    Spoken English Institute in Coimbatore
    Spoken English Course in Coimbatore
    IELTS Training in Coimbatore
    IELTS Coaching in Coimbatore
    German coaching classes in Coimbatore
    German Courses in Coimbatore

    ReplyDelete
  34. This comment has been removed by the author.

    ReplyDelete
  35. You have provided a nice article, Thank you very much for this one. And I hope this will be useful for many people. And I am waiting for your next post keep on updating these kinds of knowledgeable things
    Spoken English Classes in Chennai
    Best Spoken English Classes in Chennai
    Spoken English Classes in Chennai
    Best Spoken English Classes in Chennai
    spoken english classes in bangalore
    english speaking course in bangalore

    ReplyDelete
  36. Rugby World Cup matches live stream free online. How to watch Rugby World Cup 2019 Japan live stream & Find RWC 2019 schedule, TV channel, news update.

    Rugby World Cup

    ReplyDelete
  37. Rugby World Cup matches live stream free online. How to watch Rugby World Cup 2019 Japan live stream & Find RWC 2019 schedule, TV channel, news update.

    rugby world cup matches

    ReplyDelete
  38. Great blog thanks for sharing Consistent and relevant content is the best ways to drive in massive amounts of traffic to your website through Search Engines. Adhuntt Media’s content creation team has got everything covered for you - from high-grade blogs that engage the reader and hit all the sweet SEO spots, unique design posts for your social media feed and professional videos for video marketing.
    digital marketing company in chennai

    ReplyDelete

  39. Really appreciate this wonderful post that you have provided for us.Great site and a great topic as well I really get amazed to read this. It's really good.
    I like viewing web sites which comprehend the price of delivering the excellent useful resource free of charge. I truly adored reading your posting. Thank you!.
    mobile phone repair in Fredericksburg
    iphone repair in Fredericksburg
    cell phone repair in Fredericksburg
    phone repair in Fredericksburg
    tablet repair in Fredericksburg
    mobile phone repair in Fredericksburg
    mobile phone repair Fredericksburg
    iphone repair Fredericksburg
    cell phone repair Fredericksburg
    phone repair Fredericksburg


    ReplyDelete
  40. The memory cards or rather flash memory cards are chips allowing users to write and rewrite data over and over. They come in small sizes and have the ability to retain data without a power supply.
    https://www.hugdiy.com/custom-usb

    ReplyDelete
  41. I have browsed most of your posts. This post is probably where I got the most useful information for my research.
    Click here for Printing Online Visiting Cards & ID.

    ReplyDelete
  42. The Kansas City Chiefs are a Kansas City Chiefs Game Watch Online professional NFL team based in Kansas City, Missouri. You can watch Kansas City Chiefs game live streaming online. Get the latest Kansas City Chiefs schedule, TV channel, news update here.
    Watch Chiefs Game Today
    Chiefs Football Live Online
    Chiefs NFL Football Live
    Kansas City Chiefs Football Live
    Chiefs NFL Game 2020 Live
    Chiefs NFL Game Live
    Chiefs NFL Game Live Online
    Watch Chiefs Game Online

    ReplyDelete
  43. We supply turn-key solutions for your specific diamond needs, from custom made designs to delivering exemplary diamond solutions. heart diamond exporter

    ReplyDelete
  44. This comment has been removed by the author.

    ReplyDelete
  45. This is the complete March Madness schedule for 2022, beginning with Selection Sunday on March 13. Here is a complete guide to watch March Madness 2022 online from anywhere without cable. March Madness 2022 Live from available at home.

    ReplyDelete
  46. I truly awed after read this content. Do you want to improve your language skills but find it difficult to attend traditional tuition classes. Enroll in Ziyyara’s online English tuition classes today and get a chance for a free demo.
    For more info visit Online English Tuition

    ReplyDelete
  47. Nice blog was really feeling good to read it. Thanks for this information. Ziyyara Edutech’s private tuition classes for Class 11 provide comprehensive and personalized learning experiences, tailored specifically to meet the needs of Class 11 students.
    For more info Contact us: +91-9654271931, +971-505593798 or visit online tutoring sites for class 11

    ReplyDelete