Hi guys,
I'm a new javascript dev. and I don't know how to check (at OnSave) if a field equipment id on contract detail form already exists for a contractid.
I've trying something like this:
var equipm = crmForm.all.wttl_baseinstaladaid.DataValue[0].id; //lookup field var contract = crmForm.all.contractid.DataValue; if(contract, equipm) { alert('equipment id already exists for this contract'); event.returnValue = false; event.cancelBubble = true; return false; }
However, I know that this condition is based on a method. But i don't have code access.
For this case, can i use fetchxml or just a trigger?
Thanks.
Btw, sorry about the bad english.