Sadsmileyface
New Member
- Joined
- Mar 21, 2013
- Messages
- 11
I had some lifesaving advice on here a while back and it's peaked my curiosity with what I can do. I've had a conundrum and have been Googling the answer to try to find it on my own without having to resort to asking but I've hit a brick wall. I'm kind of doubting this can be done.
I have a folder full of word docs, all in a similar format. In each word doc, I want Excel to open and search for a text string (as predetermined in cells in excel) and return the value it find after a colon, and past it into a cell. That's mostly easy.
Then, I want to search for a string in the doc again and return something like true or false in the adjacent cell in Excel. Again, not too bad.
However, my problem is that that second set of strings we're searching for are not necessarily going to be unique in the document. The only thing to differentiate them will be a heading above them. I've illustrated this here (strings in italics are searched, bold is returned strings, underlined is logic):
Name: JOHN SMITH
Date: 10-Mar-2018
Level: 1
Code Reference: 2.1.2 A RETURN TRUE OR FALSE
Code Reference: 2.1.2 B RETURN TRUE OR FALSE
Code Reference: 2.1.2 C RETURN TRUE OR FALSE
Level: 2
Code Reference: 2.1.2 A RETURN TRUE OR FALSE
Code Reference: 2.1.2 B RETURN TRUE OR FALSE
Code Reference: 2.1.2 C RETURN TRUE OR FALSE
So then we'd want to populate a range like this in Excel:
<tbody>
</tbody>
Is this even possible or am I way up the wrong tree?
I have a folder full of word docs, all in a similar format. In each word doc, I want Excel to open and search for a text string (as predetermined in cells in excel) and return the value it find after a colon, and past it into a cell. That's mostly easy.
Then, I want to search for a string in the doc again and return something like true or false in the adjacent cell in Excel. Again, not too bad.
However, my problem is that that second set of strings we're searching for are not necessarily going to be unique in the document. The only thing to differentiate them will be a heading above them. I've illustrated this here (strings in italics are searched, bold is returned strings, underlined is logic):
Name: JOHN SMITH
Date: 10-Mar-2018
Level: 1
Code Reference: 2.1.2 A RETURN TRUE OR FALSE
Code Reference: 2.1.2 B RETURN TRUE OR FALSE
Code Reference: 2.1.2 C RETURN TRUE OR FALSE
Level: 2
Code Reference: 2.1.2 A RETURN TRUE OR FALSE
Code Reference: 2.1.2 B RETURN TRUE OR FALSE
Code Reference: 2.1.2 C RETURN TRUE OR FALSE
So then we'd want to populate a range like this in Excel:
<tbody> </tbody> |
<tbody> </tbody> |
<tbody> </tbody> |
<tbody> </tbody> |
<tbody> </tbody> |
<tbody> </tbody> | ||||||
<tbody> </tbody> |
<tbody> </tbody> | 1 | TRUE | TRUE | FALSE | ||||||
<tbody> </tbody> |
<tbody> </tbody> | 2 | FALSE | FALSE | TRUE |
<tbody>
</tbody>
Is this even possible or am I way up the wrong tree?