+ Reply to Thread
Results 1 to 3 of 3

Find and Replace in Word document from Excel macro

  1. #1
    Registered User
    Join Date
    01-25-2015
    Location
    Veghel, The Netherlands
    MS-Off Ver
    Microsoft Office 2013
    Posts
    2

    Find and Replace in Word document from Excel macro

    Hello,

    I'm building a sheet to maken offers in Microsoft Word with data from Excel.
    I would like to open a Word document from a Excel macro and find and replace all.
    This code works, only I can find and replace more then one of the same text.

    I already tried Replace:=wdReplaceAll but this doesn't work.
    Someone has tips to get this working?

    Please Login or Register  to view this content.

  2. #2
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Find and Replace in Word document from Excel macro

    I'm not sure that Excel VBA would have access to Word's VBA constants. Try Replace:=2
    _
    ...How to Cross-post politely...
    ..Wrap code by selecting the code and clicking the # or read this. Thank you.

  3. #3
    Registered User
    Join Date
    01-25-2015
    Location
    Veghel, The Netherlands
    MS-Off Ver
    Microsoft Office 2013
    Posts
    2

    Re: Find and Replace in Word document from Excel macro

    Hi mikerickson,

    Thanks voor your reaction!
    I already tried 2 and 3.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Find and Replace in Word document through Excel VBA
    By javi-xls in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-22-2014, 11:14 PM
  2. [SOLVED] Find and replace in word document
    By bruizer31 in forum Excel Programming / VBA / Macros
    Replies: 26
    Last Post: 06-18-2013, 09:14 PM
  3. Use Excel VBA for editing and find/replace in a Word document
    By drdavidge in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 01-05-2013, 06:10 AM
  4. Highlight certain words in Word document after running find-and-replace from Excel
    By EnterTheSerpent in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-22-2012, 02:27 PM
  5. Find and Replace the styles in the word document
    By nnram123 in forum Word Formatting & General
    Replies: 2
    Last Post: 12-21-2010, 01:52 PM

Tags for this Thread

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