This would be a better version of the hack above…
//you can use a hack-ish function to format all instances correctly//and avoid hardcoding labels...<br>function fixFieldFormat(val){<br> if(val.indexOf("__c") != -1){<br> var trim__c = val.replace("__c","");<br> var trim_ = trim__c.replace(/_/g," ");<br> }<br> return trim_;<br>}<br>//then just call it<br>value1 = fixFieldFormat(value1);