Thank you for taking the challenge to help!!
I need a Macro to automate search and check function in Microsoft Excel. In the following example, the Macro should search each cell in column-A (STAFF MEMBERS) with keywords from B1 (DARK HAIR), C1, D1 ... etc. For a search match (between keywords and STAFF MEMBER column), enter "1", otherwise enter "0" in the corresponding cell of the row. The challenges are two: 1) negation statement -- "No dark hair" is NOT a match to keywords "DARK HAIR" nor is "Daily jog is not ... " to "DAILY JOG"; other negation statements may be "cannot (jog daily)", "negative for (DARK HAIR)", " ... is negative" and "free of (SUN BURN)". 2) semantic unit. # is used as a marker for each semantic unit. The search has to treat one cell as multiple units.
A B C D E F 1 STAFF MEMBERS DARK HAIR RED SOX FAN DAILY JOG SUN BURN ... 2 Jack: #Dark hair. #No sun burn. #Red Sox fan. 1 1 0 0 ... 3 Jill: #No dark hair. #Red socks fan. #free of sun burn. 0 1 0 0 ... 4 Sam: #Daily jog is not reported. #dark hair. 1 0 0 0 ... 5 Joe: #Negative for sun burn. #cannot daily jog. #Dark hair. 1 0 0 0 ... 5 ... ... ... ... ... ... ...
Bookmarks