I've been scratching my head on this one for the past couple of days and wonder if anyone can help? I've seen a couple of similar queries here but when I've tried to implement the results I've not had any luck.
I'm trying to set the default value of a fee field to 150 when the loan type and loan purpose meet specific criteria, so far I've had no luck!
Below is what I've tried using most recently.
var Application = CRM.FindRecord('application',Value('appl_applicationid')); var loanType = CRM.GetContextInfo("Application","appl_loantype"); if (Application.appl_loan_purpose == 'Purchase' && loanType == 'Buy') { DefaultValue = 150; } else { DefaultValue = 100; }
Thanks!
James.