Jan 07 2023 12:55 PM
I have used Data Validation in cell F4 to create a drop down of three names. Based on which name is selected, I would like cell F5 to populate a particular email address and also leave blank if cell F4 has not been selected. When I input the below, I receive the #Name? error. Can someone please review and let me know what I am doing incorrectly? Thanks in advance
=IF(F4=Anna, "email address removed for privacy reasons",IF(F4=Sally,"email address removed for privacy reasons",IF(F4=Diana,"email address removed for privacy reasons")))
Jan 07 2023 01:18 PM
SolutionLiteral text strings must be enclosed in quotes:
=IF(F4="Anna", ..., IF(F4="Sally", ..., IF(F4="Diana, ..., "")))
or
=IFS(F4="Anna", ..., F4="Sally", ..., F4="Diana", ..., TRUE, "")
Jan 07 2023 01:29 PM
Jan 07 2023 02:05 PM
Did you add , "" before the closing parentheses? That should make the formula return an empty string "" if you haven't entered any of the specified names.
Jan 07 2023 01:18 PM
SolutionLiteral text strings must be enclosed in quotes:
=IF(F4="Anna", ..., IF(F4="Sally", ..., IF(F4="Diana, ..., "")))
or
=IFS(F4="Anna", ..., F4="Sally", ..., F4="Diana", ..., TRUE, "")