You need to sign in to do that
Don't have an account?
JuanTal
I can't update a custom field with a custom button
I have this but doesn't work
any ideas ?
{!REQUIRESCRIPT("/soap/ajax/8.0/connection.js")};
var caseObj = new sforce.SObject("Factura__c");
caseObj.Name = "{!Factura__c.Name}";
caseObj.Detalle__c = "005A0000001Sb6m";
var result = sforce.connection.update([caseObj]);
window.location.href=window.location.href;
I propose that the most likely scenario is that you are neglecting to include the "ID" field, which would cause this type of error; you can never update a record without an ID value present.
Add the following code before your update call: