Forum Discussion
Return a value from a list depending if value in another cell contains this
- Dec 14, 2021
See the attached sample workbook. The Parts and Sizes names are dynamic in this version - they will automatically be adjusted when you add or remove part numbers. See Formulas > Name Manager for their definition.
Hi martin7b
You may take help from SEARCH() functions, assume the parts numbers are stored in column A then use below formula column B.
=IF(IFERROR(SEARCH("TR",A3,1),0)>0,"Small",IF(IFERROR(SEARCH("PN",A3,1),0)>0,"Big",IF(IFERROR(SEARCH("CWR",A3,1),0)>0,"Middle","Large")))
You may also refer to the attached sample file for more understanding.
Thanks
Tauqeer
Thanks for your quick answer - I have this solution - the issue is that the list with the codes is very long (+50 different codes and this makes the formula very long as well) - we are also modifying the list from time to time so I would like to have it dynamic for an enduser who is not familiar with formulas so he just can edit the list. sorry for the missing additional information from my side in the innitial post. Any idea?
Thanks