Discussion Locked

Copy lines of Outlook Email to Excel

0 helpful
14 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I have a situation where I have emails coming in from a particular email address and I want to copy the data automatically to Excel. The information that I am looking for is located between two lines that look like this: "============"
Each line is comprised of 9 different "columns" with fixed "field widths". I can copy the information to excel manually and then do a text to columns function but the problem is that I get between 200 to 600 of these emails a day and I don't have the time to create an excel database manually by copying and pasting from the email. Can anyone help me figure out a method to isolate the specific field widths for each line between the "=====" lines?

14 replies

by otl

I have found no direct way to convert from a standard text file to excel or access but if the file names are all the same [ie: (site)(file#sent).(txt)] conversion can be accomplished via (bite my tong) DBASE or another database manipulitive program such as paradox/foxbase. These are easily converted to a text tab delimited formatfor import to EXCEL. The drawback is you have to take a break while these are re-routing and compiling the data.

by sheryl v

If you put a batch of e-mails in a specific folder, Outlook has an export wizard that will let you export all messages in a folder to a csv file. If you only export the "BODY" field and you always export it to the same place & file, you can then create a macro in Excel that will open the current txt file & use "=" as a field separator, when you create you're auto import macro, be sure to check the box to treat consecutive delimitors as one. I would use Access rather than excel & save the import specifications so you can append all records to the full database in one fell swoop . Hope this points you in a helpful direction.

by sheryl v

If you use rules, you can automatically have all these particular e-mails automatically going to the "Export" folder, then you have 2 manual steps (export/run import) that you can do when periodically. Using Access & import specs, you could have anautexec macro that automatically imports when you open the db.

by sheryl v

If you put a batch of e-mails in a specific folder, Outlook has an export wizard that will let you export all messages in a folder to a csv file. If you only export the "BODY" field and you always export it to the same place & file, you can then create a macro in Excel that will open the current txt file & use "=" as a field separator, when you create you're auto import macro, be sure to check the box to treat consecutive delimitors as one. I would use Access rather than excel & save the import specifications so you can append all records to the full database in one fell swoop . Hope this points you in a helpful direction.

by sheryl v

oops - tried to catch the supscribe to box & submit again & it ended up submitting twice. :)

by james_randy

If you are still tackling this problem, perhaps you should consider calling your local super-hero.

by conrad

In completing one discovery we never fail to get an imperfect knowledge of others of which we could have no idea before, so that we cannot solve one doubt without creating several new ones.

- Joseph Priestly, 1786

This discussion is closed to new replies.