You need to sign in to do that
Don't have an account?

Update call in S-control no longer working
We have had an s-control update a parent record with some number values from a child record. It has worked perfectly up until now, but now the fields we are trying to update on the parent record comes up as zero - no matter the actual value of child record fields are.
Here's the update call section of the s-control:
var update_oppt = new sforce.SObject('Opportunity');
update_oppt.id = "{!Funnel_Scorecard__c.OpportunityId__c}";
update_oppt.Latest_Funnel_Scorecard_Total__c = totals[0].Total__c;
update_oppt.Latest_Business_Criteria_Subtotal__c = totals[0].Business_Criteria_Subtotal__c;
update_oppt.Latest_Opportunity_Criteria_Subtotal__c = totals[0].Opportunity_Criteria_Subtotal__c;
update_oppt.id = "{!Funnel_Scorecard__c.OpportunityId__c}";
update_oppt.Latest_Funnel_Scorecard_Total__c = totals[0].Total__c;
update_oppt.Latest_Business_Criteria_Subtotal__c = totals[0].Business_Criteria_Subtotal__c;
update_oppt.Latest_Opportunity_Criteria_Subtotal__c = totals[0].Opportunity_Criteria_Subtotal__c;
var save_oppt = sforce.connection.update([update_oppt]);
The fields we are trying to update are number fields - if I change these to update text fields, it all of a sudden it works...
Considering this has worked for months, and we've made no changes to any configuration - does anyone have an idea as to why this does not work anymore? Any updates or changes Salesforce.com has done perhaps?
The number values in the array does show up as 34.0 for example - could it be mistaking this for a text value for some reason? I realize I'm reaching here, but I'm just completely lost as to why this does not work anymore...
Any thoughts?
Thanks!
update_oppt.Latest_Business_Criteria_Subtotal__c = totals[0].Business_Criteria_Subtotal__c*1;
update_oppt.Latest_Opportunity_Criteria_Subtotal__c = totals[0].Opportunity_Criteria_Subtotal__c*1;