Lookup controls have a specific object type for a DataValue. This is an array of objects that look like this:
{ id: , typename: , name: }
If you want to remove all values ββfrom the search, you can set it to null, but it's better to just set it to an empty array.
If you assign a value, but it does not change anything, you most likely will not type the correct identifier for the attribute. For example: if I have an object with the lookup attribute sneakers_brokerid , then I need to assign this value as follows:
crmForm.all.sneakers_brokerid.DataValue = [];
source share