1

I have contact lookup in task. If I choose contact then it should show only related contacts to Account. I put the filter condition as follows

Activity: Related To ID equals Contact: Account ID

The above condition works fine if I create task from Account related list as Related To ID matches the Account Id whereas if I try to create task from Opportunity related list its not showing any contact as Related To ID in this case is Opportunity Id not Account Id.

I need to get Contact of parent Account as well for that I use the below condition

Activity: Related To ID equals Contact: Account:Parent Account ID

Is that possible to get the Contact of parent Account if so how to get that?

2

Since Contacts are not related to Opportunity that's why no Contact is displaying if you have that look up filter.

You should change the look up filter like this upon introducing the Id check for Account (001) and Opportunity (006).

Task look up filter

Outcome:

  1. Create Task from Account - it will filter all the contacts related to Account

  2. Create Task from Opportunity - it will display all the contacts (25 records per page) as no filter is applicable here.

Update

Based on revised question if you want to include Grant Parent Account then it will be like this where contacts related to either of Parent Account or Grant Parent account will get filtered.

Task filter on grant parent account

If you select Grant Parent Account then contacts both Grant Parent and Parents will get displayed.

If you select Parent Account then contacts of only Parent Account will get displayed. This time, contacts of Grant Parent will not be displayed.

(I have assumed then user has access to all the Account Levels).

  • Find updated answer – Santanu Boral Mar 26 '17 at 20:36
  • Activity: Related To ID equals Contact: Account:Parent Account ID will not work as Related to ID(Current Account Choosen) doesn't has match with Account:Parent Account ID(Grant parent ID differs from Related to ID). Any other way to tackle this? – Sankar Ganesh Mar 27 '17 at 14:23
  • That is the expected behavior. I dont think standard way, you can do that. You need to write Visualforce for that functionality then. – Santanu Boral Mar 27 '17 at 17:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.