What is Issue?
Sometimes we need to filter out the lookup fields according to business requirement. So generally we try to apply custom filter using client side scripting (JavaScript). This filtration works for normal lookup fields (datatype Lookup), but when it comes to fields like Regarding object,Required,Optional fields (PartyList Datatype fields) on Activity forms(Appointments/Phone call) the script fails. It won’t filter the field continues to show default results for Accounts .
The Reason-
You will face this issue because the party list shows the results for all the entities like Accounts, contacts, lead,User and depending on the entity selected in “Look for” in Lookup More result window.
Solution-
The Solution for this issue is to set the “Look For” value before filtering the lookup to limit the search according to business requirement. Use the following code to set the “Look For” in Lookup More Window-
This will set Look For as well as will apply the custom filter to your field.
Enjoy MS CRM!!!
[…] You can refer My other blog post related to this one – Filter Required/Regarding (partylist data type) fields… […]
LikeLike