Disclaimer: I am a beginner with VBA.
I started off trying to create a VBA code that would extract certain text from a folder full of .msg files (Outlook 2007) and put them in a a blank workbook.
After a lot of google it seemed to me that its impossible to get a text stream to parse from msg files. So I tried to save a few of the msg files as txt files and used the following code on it. It worked fine!
Now the challenge is, I tried a code to batch rename the extension of the .msg files to .txt files. Just renaming the files (Not SaveAs txt) results in files with a lot of garbage headers in the file and the code doesn't work.
Please help me with some code which would either:
A> create a text stream directly from .msg files OR
B> copy the legible section of the renamed files into a temporary txt file for parsing OR
C> modify the code to work in spite of the garbage headers OR
D> any other ideas to make this work that I didn't think of.
Please check the attached zip files with all the working files.
Bookmarks