• Joanna Moya 9
  • NEWBIE
  • 0 Points
  • Member since 2018

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 0
    Replies
Hello Developer Friends, I am trying to create a list view button that will mark a case as Spam (custome checkbox field) and Update the Case Status to Resolved. The below is what I've got but I know it is worng. Any help is appreciated!

Thank you and be well!

Jo
 
{!REQUIRESCRIPT("/soap/ajax/29.0/connection.js")}

var record = new sforce.SObject("Case");  

c.Is_Spam__c = 'true';
caseObj.Status = 'Resolved';
record.Id = "{!Case.Id}";


var result = sforce.connection.update([record]);
window.location.reload();