Results 1 to 11 of 11
  1. #1
    Star Lounger
    Join Date
    Feb 2005
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Replace colours throughout documents (Word 2003)

    Dear Loungers,

    I have a few dozens of long documents that were created with old template. The old template uses Green color throughout the headings, table borders (including shading). We are migrating to new colour scheme. My problem is that the documents were not properly style-d, hence changing the styles do not create clean documents. Is there a quick way (VBA or trick) to replace all greens that appear throughout the document to, say, blue?

    Any advise is very much appreciated.

    Regards
    Rid

  2. #2
    5 Star Lounger
    Join Date
    Aug 2001
    Location
    Confoederatio Helvetica
    Posts
    602
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Not a trick, but doesn't a simple Search and Replace work? i.e. Under Edit --> Replace leave the Find what and Replace with boxes empty, but while the curser is in each of these boxes click on Format (after clicking on More) then Font and select the find colour. Do the same with the curser in the replace box.
    Good luck

  3. #3
    Platinum Lounger
    Join Date
    Jan 2001
    Location
    Quedgeley, Gloucester, England
    Posts
    5,333
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Replace colours throughout documents (Word 200

    Is your use of curser a Freudian slip?!

    John
    <font face="Script MT Bold"><font color=blue><big><big>John</big></big></font color=blue></font face=script>

    Ita, esto, quidcumque...

  4. #4
    Star Lounger
    Join Date
    Feb 2005
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Thank you.

    It works for text, but how about cell border and Shading; text box fill colour?

    Regards
    Rid

  5. #5
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Replace colours throughout documents (Word 200

    Would it be possible to create a custom table AutoFormat and apply that to all tables, or do the tables have individual characteristics?

    The following macro will change the fill color for all text boxes from green to blue:

    Sub ColorTextBoxes()
    Dim sh As Shape
    For Each sh In ActiveDocument.Shapes
    If sh.Type = msoTextBox Then
    If sh.Fill.ForeColor = vbGreen Then
    sh.Fill.ForeColor = vbBlue
    End If
    End If
    Next sh
    End Sub

    You may have to use different colors.

  6. #6
    Star Lounger
    Join Date
    Feb 2005
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Thanks Hans,

    You read my 'nightmare' well. Yes, if the users could use different formats on text (even after styles are created for them), you could imagine how messy the tables produced. I am trying to avoid re-creating the tables, if I could simply "search and replace" the colours and shadings.

    Regards,
    Rid

  7. #7
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Replace colours throughout documents (Word 200

    But do you want the tables to remain messy, or would you prefer to impose a uniform formatting? If you allow the mess to remain, you'll have the same problem next time.

  8. #8
    5 Star Lounger
    Join Date
    Aug 2001
    Location
    Confoederatio Helvetica
    Posts
    602
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Suppose so, happens whenever I think of MS <img src=/S/evilgrin.gif border=0 alt=evilgrin width=15 height=15> - Now John, you must stop <img src=/S/pirate.gif border=0 alt=pirate width=22 height=18> <img src=/S/jollyroger.gif border=0 alt=jollyroger width=29 height=18> these 'serious' threads.

    I was actually impressed that I got a reply in before Hans - he must have had a lie-in this morning. <img src=/S/doze.gif border=0 alt=doze width=15 height=15>

  9. #9
    Star Lounger
    Join Date
    Feb 2005
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Hans,

    In this case, the documents do not 'deserve' 100% treatment anymore, as they will become obsolete by the end of this year. But the boss still wants to do the extra steps and wants the colours in the documents to be changed. In other words, I want easy way out, if it is at all possible. :-) I don't mind using Table Auto Format if the tables have patterns. But the cells are merged here and there; one cell of a row is shaded; whilst other similar tables are not. To put it crudely, I don't know what the creators were doing.

    Regards
    Rid

  10. #10
    3 Star Lounger
    Join Date
    Apr 2004
    Location
    Boston, Massachusetts, USA
    Posts
    389
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    It's probably not as easy as you'd hoped, but it's certainly possible to do something like this from RTF (where it would be a fairly straightforward serach/replace of one color-code for another).

    If possible, could you post a pair of (short) documents -- one "before" with the green you don't want, and one "after", with the color you want instead?

  11. #11
    Star Lounger
    Join Date
    Feb 2005
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Replace colours throughout documents (Word 200

    Thank you everyone and sorry for replying late.

    The good news is I have managed to convince the boss to use PDF instead. I used plug-in to Acrobat to convert the old colours to the new ones.

    Again thank you.

    Regards
    Rid

Posting Permissions

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