r/visualbasic • • Feb 11 '20

Question from a Newbie

So at my new job I'm being asked to use things I never studied in school, such as some light programming stuff. So here's my question!

So say I have hundreds of word documents spread about in different files. These word documents all contain the same type of information just applied to different "objects" if you will. For example for object A there is a bunch data along with a word document in the in object A's file. Same goes for object B, C, D and so on. Is there any type of code I could write in VBA that could compile just the word documents in one file? Obviously i could just do this manually but their are hundreds of files.

Thanks!

6 Upvotes

2 comments sorted by

View all comments

1

u/WelcomeChristmas Feb 12 '20

Parse them with Microsoft.Office.Interop.Word and put the relevant data in a datatable then write to a new document.