+ Reply to Thread
Results 1 to 8 of 8

Find and extract data from word and paste into Excel

  1. #1
    Registered User
    Join Date
    09-18-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    47

    Find and extract data from word and paste into Excel

    Hey guys,

    Got a tough problem with a document and worksheet. I have a document that has about 450 pages with parameters and values listed in exactly the same order. I need to find 4 specific variables and copy the data from the document and paste them into an excel spreadsheet. I need to find and list the Source, Parameter Type, Parameter Value, and Engineering Units. The attached document is a page from the large document. The attached workbook is how I need to have the list created. As of right now I have been copying and pasting but that takes days to do.

    I can somewhat understand how a code works when it is written but I don't know where to start. Any help would be greatly appreciated.

    Thanks,
    Pat
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Find and extract data from word and paste into Excel

    I can only see 4 heading, nothing else

  3. #3
    Registered User
    Join Date
    09-18-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    47

    Re: Find and extract data from word and paste into Excel

    The information is in the attached word document.
    For instance the first parameter in the document is this:
    Report: Step Parameter
    Name: PR_MFPL_CIP_S2/UP_CIP_S2:1/ABT_AIR_DLY_TM
    Parameter Category: Process Input
    Parameter Type: Integer
    Low Limit: 0
    Parameter Value: 10
    High Limit: 9999
    Engineering Units: sec
    Scalable: False
    Origin: Defer
    Source: ABT_AIR_DLY_TM

    I need to copy the Source, Parameter Type, Parameter Value and Engineering units into an excel spreadsheet. The attached workbook is just an example of how I need to list the information

  4. #4
    Registered User
    Join Date
    09-18-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    47

    Re: Find and extract data from word and paste into Excel

    Anyone???

    Bueller??

    LOL

  5. #5
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Find and extract data from word and paste into Excel

    hi Patrick, please check attachment, press Run button, choose file .docx with the data structure specified in the sample file posted. Basing on your sample some parameters might be absent (Engeneering Units)
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    09-18-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    47

    Re: Find and extract data from word and paste into Excel

    Thank you so much, that it awesome works like a charm

  7. #7
    Registered User
    Join Date
    09-18-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    47

    Re: Find and extract data from word and paste into Excel

    Is there a way I can look through the code and try to under stand it a little more? When I open up VBA, I can seem to locate your code. Also is it possible to do the same exact thing with a PDF in the same format. Virtually the same document just in pdf form. When I save the PDF as a word document, it cuts off some of the information and inserts it into a footer
    Last edited by oneillp1; 03-05-2013 at 02:04 PM.

  8. #8
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Find and extract data from word and paste into Excel

    re code: the code creates word object, opens selected document, filters out unnecessary fields leaving Report field as a delimiter between data blocks, loops the filtered data to create result data table, outputs result to Excel, kills word object.
    re pdf: I don't know for now what can be done there

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1