function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Shashank SomwanshiShashank Somwanshi 

how to Create a dependent text field controlled by a lookup field

I have one picklist field. Which i want to be controlled of dependent on my lookup field value. For eg: If i select ABC on my lookup. Then 1,2,3 will only be select option on my picklist value. 
Best Answer chosen by Shashank Somwanshi
Suraj Tripathi 47Suraj Tripathi 47

Hi Shashank,

You can't hide the pick list values with the select of other pick list. 

we can write a trigger on it when we select ABC from Account then we can restrict the user for selecting 4,5 out of 1,2,3,4,5(Contact).

we can restrict the use by giving them error you can't select this.

So user can only select 1,2,3 when ABC selected.

Is it feasible if yes then please tell me I will write the trigger.

Thank You

All Answers

Suraj Tripathi 47Suraj Tripathi 47

Hi Shashank,

You can't hide the pick list values with the select of other pick list. 

we can write a trigger on it when we select ABC from Account then we can restrict the user for selecting 4,5 out of 1,2,3,4,5(Contact).

we can restrict the use by giving them error you can't select this.

So user can only select 1,2,3 when ABC selected.

Is it feasible if yes then please tell me I will write the trigger.

Thank You

This was selected as the best answer
Shashank SomwanshiShashank Somwanshi
Thanks Suraj,
I got it