Let's say I have a list of 5 keyword phrases as below:
CellA1 guitar chords
CellA2 guitar chord
CellA3 guitar chords with scores
CellA4 guitar chords expert
CellA5 guitar chords with scores of music
The macro will begin with CellA1 and check the rest of the list (CellA2 till end of list) for any cell that contains the contents of CellA1. Once it is able to find an instance for that, it returns "YES" in CellB1. In this case, the first instance is found in CellA3 and so CellB1 returns "YES".
Next, the macro moves to CellA2 and check the rest of the list (CellA3 till end of list) for any cell that contains the contents of CellA2. CellA2 contains "guitar chord" so the macro will check CellA3 till CellA5 on whether they contain "guitar chord". In this case, CellB2 will return "NO" as there is no cell that contains "guitar chord" exactly. That means "guitar chords with scores" is a "NO" while for example "guitar chord with scores" is a "YES".
The macro then moves on to subsequent cells down ColumnA to keep on checking until the end of list.
This is just a make-up list of 5 phrases. What I require is a general macro that can handle at least 5000 phrases.
CellA1 guitar chords
CellA2 guitar chord
CellA3 guitar chords with scores
CellA4 guitar chords expert
CellA5 guitar chords with scores of music
The macro will begin with CellA1 and check the rest of the list (CellA2 till end of list) for any cell that contains the contents of CellA1. Once it is able to find an instance for that, it returns "YES" in CellB1. In this case, the first instance is found in CellA3 and so CellB1 returns "YES".
Next, the macro moves to CellA2 and check the rest of the list (CellA3 till end of list) for any cell that contains the contents of CellA2. CellA2 contains "guitar chord" so the macro will check CellA3 till CellA5 on whether they contain "guitar chord". In this case, CellB2 will return "NO" as there is no cell that contains "guitar chord" exactly. That means "guitar chords with scores" is a "NO" while for example "guitar chord with scores" is a "YES".
The macro then moves on to subsequent cells down ColumnA to keep on checking until the end of list.
This is just a make-up list of 5 phrases. What I require is a general macro that can handle at least 5000 phrases.