![]() |
#7
|
||||
|
||||
![]()
Sure,
If you put the list of colours, say red, blue and orange into cells J1:J3, two options would be: (1) Use the same formula as above, but with the array constant replaced by the range and enter it as an array formula. To do this, when you type the formula into the formula bar, finish the entry with CTRL+SHIFT+ENTER instead of just ENTER. If done correctly then Excel will automatically surround the formula with braces { } (you can't manually enter these yourself). Code:
{=IF(OR(ISNUMBER(SEARCH(J1:J3,A1))),B1,0)} Use a variation such as this one (which can be entered as a normal formula). Code:
=IF(SUMPRODUCT(--ISNUMBER(SEARCH(J1:J3,A1))),B1,0) |
Tags |
if-then, text dependency |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Macro to find text in between two characters and then format selected text? | qcom | Word | 5 | 02-19-2015 11:23 PM |
![]() |
simpleonline1234 | Word VBA | 1 | 02-25-2011 02:28 AM |
Objective: Automatically export email text,attachment text to DB friendly format | SilentLee | Outlook | 0 | 11-14-2010 02:45 PM |
Templates: automatic text generation from Rich Text content control | Chickenmunga | Word | 0 | 10-01-2008 11:16 AM |
Cells with wrap text not showing text | lazylew | Excel | 1 | 08-31-2008 06:58 AM |