Adding custom buttons in body of a page?

OK I would try debugging by console logging everything. Take all your variables and use

console.log(yourVar);

Press Ctrl + Shift + J to open the console in chrome, and see what you get…

Hi Moshe this wasn’t working:

var caseId =sforce.apex.execute(“RetrieveNextUtilsSkuid”, “retrieveNextCase”, {});

Once I changed it to this, it worked fine, just thought you might want to know and thanks for your help again

var caseId = new String(sforce.apex.execute(“RetrieveNextUtilsSkuid”, “retrieveNextCase”, {}));

Hi Moshe I have a javascript snippet that has the following:
//Call the Apex Webservice Method
var sResponse = new String(sforce.apex.execute(“GetOutstandingItems”,“getOutstandingItems”,{QuoteId:param}));

This snippet is called with a row action on a Table (contains rows of Quotes), what I need to do is get the Id of the row (a particular Quote) and pass it to the above where param is, would you know how to do this, thanks

Hi Eddie, here is an example of the body of a Table Row Action Snippet that should work:

var params = arguments[0];<br>var rowId = params.item.row.Id;<br>//Call the Apex Webservice Method<br>var sResponse = new String(sforce.apex.execute("GetOutstandingItems","getOutstandingItems",{QuoteId:rowId}));&nbsp;<br>