1

I have a Word file with about 8,000 standard letters in it, which start with standard opening date:

26 March 2013 
XXXfew lines addressXXX 

Dear Name

paragraphs. 

I like to extract the address in CSV or Excel format. Any idea how? I am not good in macros. Can we do it in a macro?

Logic could be: Fetch anything between "Date 26th March 2013" and word "Dear".

I am using Word 2013.

1 Answer 1

0

Copy paste the letters in ColumnB of the spreadsheet. Follow the below steps:

  1. In cell A2 insert formula =A1+1 and copy paste this formula until the last cell of Column A where you find data in Column B
  2. Filter ColumnB and select only "26th March 2013". Copy paste this date to all cells in column A (without removing the filter) corresponding with the date in Column A.
  3. Filter ColumnB with "Text > Begins with > "Dear". Type "1" and copy to the corresponding cells of Column A.
  4. If you remove all of the filters in Column A you will find the address lines you are looking for starting with dates 27th March 2013 and above. The rest of the text from "Dear Name" with 1st Jan 1900 and above. Now filter Column A with dates from 27th March 2013 and you have you data ready.
  5. Copy paste the filtered data to another sheet you have your addresses extracted.

  • Have you tried copy pasting the data as mentioned in the above procedure? You just have to copy paste the 8000 letters (i do understand its a huge data running into thousands of rows) you have in one word document to the column B of the Excel Sheet starting with the first cell B1. Excel will assign them to separate rows based on the "Return" or "Enter" key you have used in the word document.
  • You have asked to extract the addresses in CSV or Excel format, hence the answer given is for Excel sheet. It does not matter if your data is in word document. The result you need is in Excel sheet. Please try the above procedure.
3
  • How I will put letters in separate rows. because ALL letters are in one ms word document.
    – Developer
    Mar 27, 2013 at 14:23
  • above you are talking about filtering. and excel file while my data is in word document.
    – Developer
    Mar 27, 2013 at 14:35
  • Kishore, please register here on the site to keep your account. Go to Contact us at the bottom if you have issues. You can then always edit your posts for updates.
    – slhck
    Mar 28, 2013 at 13:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .