Word: Find and highlight multiple words at once

November 6, 2015

This is a variation on the multiple find/replace macro covered here: https://cybertext.wordpress.com/2015/03/03/word-macro-to-run-multiple-wildcard-find-and-replace-routines/. I suggest you read that post first (and test it) before attempting this one. This post assumes you can already do what’s in that earlier post.


The scenario for this one is a little different — the author wanted to find various words in a document and highlight them for probable change. As there were MANY documents she had to process, she needed an easy way to find these words and highlight them. She didn’t want to change them at this stage. The words related to project names, company names, facility names, document number prefixes, etc. One project’s documents were to be the basis of a set of documents for another project in the same company, so one of the tasks was to ‘personalize’ the copies of the original project’s documents with the names used by the new project.


Although there may be several ways you can do this, I decided to stick with what I already knew. I figured that using a variation of the ReplaceTableWithList macro (as discussed here: https://cybertext.wordpress.com/2015/03/03/word-macro-to-run-multiple-wildcard-find-and-replace-routines/) and a new table called by that macro variation should solve it. And it did.

Step 1: Create your find/replace table

  1. Start a new Word document, and create a two-column table in it.
  2. In the left column, type in the words/phrases you want to find, each on a different row.
  3. In the right column, type \1. (This means that the wildcard find/replace will replace what was found with itself — remember, you’re only trying to identify the words that *may* need changing at this point, not changing them.)
  4. Save the document to this folder, noting the name of the file as you’ll need that later:

Step 2: Set up the macro to work with the table

Add the macro below to an existing document, or better, an existing template, or even better, a central macros template that loads whenever you open Word.

Once you’ve added it, change the line that starts with sFname and has the file path — that path points to MY file on MY computer. You need to change it to YOUR file name and YOUR file path.

NOTE: Copy all the code below to the clipboard — it goes off the page, so don’t type it out as you’ll miss some of it or could make a typo.

Sub ReplaceFromTableListName()
' from Doug Robbins, Word MVP, Microsoft forums, Feb 2015, based on another macro written by Graham Mayor, Aug 2010
Dim oChanges As Document, oDoc As Document
Dim oTable As Table
Dim oRng As Range
Dim rFindText As Range, rReplacement As Range
Dim i As Long
Dim sFname As String
'Change the path in the line below to reflect the name and path of the table document
sFname = "C:\Users\rhonda\AppData\Roaming\Microsoft\Word\STARTUP\find_and_replace_routines_names_macro.docx"
Set oDoc = ActiveDocument
Set oChanges = Documents.Open(FileName:=sFname, Visible:=False)
Set oTable = oChanges.Tables(1)

' Make sure highlight is set to the colour you want, e.g. wdYellow, wdBrightGreen, wdPink, wdTurquoise
Options.DefaultHighlightColorIndex = wdTurquoise

For i = 1 To oTable.Rows.Count
 Set oRng = oDoc.Range
 Set rFindText = oTable.Cell(i, 1).Range
 rFindText.End = rFindText.End - 1
 Set rReplacement = oTable.Cell(i, 2).Range
 rReplacement.End = rReplacement.End - 1
 Selection.HomeKey wdStory
 With oRng.Find
 .MatchWildcards = True
 .Text = rFindText.Text
 .Replacement.Text = rReplacement.Text
 .Replacement.Highlight = True
 .Forward = True
 .Wrap = wdFindContinue
 .Execute Replace:=wdReplaceAll
 End With
Next i
oChanges.Close wdDoNotSaveChanges
End Sub

Step 3: Test that it works

After setting up the ReplaceFromTableListName macro (above), run it on a test document — copy an existing document and test on the copy to make sure you don’t mess up anything.


  • If you get an error message, check that you have the correct file name and path in the macro, AND check that your Word document containing the table that’s called by the macro has no empty rows.
  • If none of the words in your table get highlighted in your document on the first pass, select a highlight colour from the Home tab as though you were going to highlight manually, then run the macro again.
  • If some words are missed, check the table containing them — if a word has an initial capital in the table, but not in the document you are searching (e.g. in a URL), then the macro won’t highlight it. For words that could be capitalized in various ways, either add new lines for each variation, OR search for the part of the word you know won’t be capitalized (e.g. if you were searching for ‘Amazon’, then change the search term in the first column to ‘mazon’ to pick up the word whether it has an initial cap or not).
  • Some areas of your document won’t get highlighted, even if they contain the words you’re looking for — e.g. headers and footers, text boxes. You’ll have to check for these manually.

My author was VERY happy — she had something that only took a few seconds to run and highlighted all the various words she needed to look for.

[Links last checked November 2015]


Don’t rely on spellcheck

November 5, 2015

I’ve said it before, and I’ll say it again — a spellchecker won’t save you if the word you’ve typed incorrectly is a real word in its own right.


See also:

[Links last checked November 2015]



IP address conflicts

October 30, 2015

This post is for me, so that I remember what happened last time! (If it helps you, that’s a bonus.)

Last night we had a short (2 second) power outage. My computer was turned off at the time, whereas the others were all on and protected by UPSs. This morning, my PC couldn’t connect to anything on the network — no internet, no network drives, no Outlook. One of the messages I saw was about an IP address conflict. The network connector cable was flashing orange on my PC. I rebooted and restarted several times, but to no avail. I checked the other PCs, laptop, and tablet and they all had connection so it wasn’t a problem at the server, the network hub, or the router. Perhaps it wasn’t related to the power outage at all and was a dodgy network card? Or the new phone I got two days ago?

My laptop is connected via WiFi so I was able to do my normal early morning tasks on it while I waited for the guys at PC Guru to start work.

When I called PC Guru, they checked several things, but there was still an issue. My Guru said he could see that there was an unnamed device on the network, but he couldn’t see if the IP address was conflicting with the one on my PC. And then I remembered that there’s an IP address on our Foxtel IQ2 box, and that the box would have reset itself after the power outage! I checked Foxtel’s network settings, and sure enough, their box had picked up a new IP address — the one for my PC! (remember, my PC wasn’t on at the time of the power outage).

It’s all sorted now, and PC Guru have now named the Foxtel connection on the DHCP (??) list.

I guess as households get more and more devices connected to their systems, it will become harder to identify them all, and so the potential for IP address conflicts will increase. It would help if each device had a name in real words that could be easily recognised by real people, instead of just a MAC address and an IP address.


Plain language writing

October 29, 2015

Last week I presented a session titled Plain language writing: Tips for delivering complex messages to a general audience at the inaugural Perth Business Writers’ Conference.

The full deck of slides (but not the exercises) and the plain language alternatives handout are available on my website: http://cybertext.com.au/10490.htm

[Link last checked October 2015]


The usability of gravestones and memorial markers

October 5, 2015

Not something perhaps you’d think about… But none of us is getting out of here alive!

A bit of back story… In some of my spare time, I transcribe information for various genealogical projects and digitized newspapers. I do this from my computer, so it’s easy to volunteer a few minutes here and there, and thus help add to the wealth of information available to the world.

Recently, I found a website — BillionGraves — that has the lofty aim of photographing, mapping, and transcribing the headstones and memorials from graves throughout the world. Although some cemeteries have their records online and are searchable, many don’t, particularly those cemeteries that are no longer used and are rotting away. BillionGraves uses the power of crowdsourcing to gather and process this information. In addition to their website where you can transcribe information on headstones, BillionGraves also has an app you can download to your phone or tablet so that when you’re out and about you can visit an uncatalogued cemetery, take photos of the headstones, and upload them to the site (the geographic coordinates upload with the photos). Then you can either transcribe them yourself via the app or website, or leave them for others to do.

What a cool idea for going for a weekend drive and picnic, and having a purpose for that drive! (yes, I’m weird like that…) BillionGraves has the locations of long-lost cemeteries on its website, so you can plan to visit one that hasn’t been catalogued and that you may not even know exists because it hasn’t been used in decades. For example, in Western Australia where I live, we have many bush areas that are peppered with graves from the early settlers. The houses and settlements have long gone, but some of the graves remain.

So what has all this got to do with usability?

Remember I said that none of us is getting out of here alive? Well, most of us (at least, most of us in the ‘developed world’), will be either buried or cremated and will have either a headstone or memorial plaque made in our honor and placed in a cemetery somewhere. A little bit of forethought as to how that memorial is designed and what goes on it could make it VERY usable for future generations researching your family tree.

What’s become evident to me while transcribing other people’s information is that so much of that information is not complete, is insular (making assumptions that readers of the memorial will be reading it in the same country and century it was made, for example), and/or is unreadable.


Here are some things I recommend (in no particular order) based on what I’ve discovered while transcribing headstones etc. and based on what genealogical researchers need to know. If you have any say in what goes on a loved one’s memorial (or your own), then consider these recommendations — future generations hunting you down will love you for it!

  • Good contrast is essential. Pink granite is an awful carrier for carvings and most colors used for text — much text is unreadable, and the color and mottled nature of the granite makes it hard to photograph. Gray granite with just carved letters and no color is nearly as bad, as are gold letters on mottled gray granite (see the unreadable images below).
  • List a date of birth AND death — you don’t need ‘died aged xx years’. A date of death is usually given on a memorial, and sometimes an age at death, but rarely is a date of birth given. Genealogists put a lot of store in dates of birth AND death, and an age is just not good enough. If you state that the person died on 15 June 1985 aged 76 years, were they born in 1909 or 1908? Depending on the birth month it could be either. A date of birth is likely fewer characters to pay for than a ‘died aged xx years’ statement, AND confirms to future generations that they have the right person AND provides a date of birth if it is missing from other records.
  • List the maiden (or birth) name of a married female. Maiden names (awful term…) of females are rarely given, yet they are crucial to genealogical research. So many women in family trees get ‘lost’ when they marry as their married surname is not known. And if they marry more than once, they are even harder to find. Including the maiden name helps identify if that person is part of your family tree.
  • Use four-digit years. Two-digit years are useless. Does 15 June 85 mean 1885 or 1985? Or some other year? Memorials can last for several centuries, so make sure there is no confusion as to which one. Don’t assume that a future reader will be from the same century.
  • Write months in letters, even if abbreviated. Numeric dates only are problematic for researchers and transcribers from other countries. Does 4-5-1962 mean 4 May 1962 or April 5 1962? Depending on where you went to school, it could be either! Better to use 4 May 1962 or 5 Apr 1962 to remove any possible confusion. Using a three-letter abbreviated month is fine.
  • Use the full name of the deceased, including any middle names. Middle names are important in helping distinguish many individuals in a family tree with the same name.




Mottled gray granite with gold carved text — impossible to read from a photograph.


Pink stone of some sort (likely a sandstone not granite, but I’ve seen plenty of pink granite ones as bad), with carving but no colour used in the carved text (or it has worn off). Impossible to read from a photograph.


Good contrast, full name of deceased, has first name of wife (a bonus), dates of birth AND death, but uses numerals for the months (not too much of an issue in this case as they can be figured out by someone with a North American background and can’t be confused), and only two-digit years.


Great contrast, has dates of birth and death (with abbreviated months in letters and full years), has names of parents and siblings, has middle name.


Great contrast, has dates of birth and death (but only numerals for months so potentially confusing for a transcriber from a different country), full years, full names of both people (but no maiden name for the female), and then there’s some information that has no meaning or connection to anyone outside the family (i.e. who is ‘Pat’? a son, daughter, relation, friend??)


Even though I can’t read the language of this one (Russian?) and couldn’t transcribe it, it has great contrast, lists dates of birth and death (but months are in numerals), and uses full 4-digit years.


Handy feature for presentations

October 2, 2015

My new laptop has Windows 8.1 installed. I’m still navigating my way around it…

However, one thing I found looks like it would be very useful when I’m giving a presentation from the laptop, or if I want to work uninterrupted, and that’s a quick and easy way to turn off notifications for a period of time for 1, 3, or 8 hours.

You point to the far top right of the desktop until the slider opens, then click the settings icon (the cog), then Notifications, then choose your ‘quiet time’.

Alternatively, search for Notifications, then either select Hide Notifications Temporarily or Notifications to specify a specific time range and notifications from specific apps.


Starting a sentence with a conjunction

October 1, 2015

Based on a Writing Tip I wrote for my work colleagues.


One of the authors asked me about starting a sentence with Because:

I was curious about a change you made. The original paragraph started with “As the trunkline fluids….” and you changed it to “Because the trunkline fluids……”

As Because the trunkline fluids will spread and weather rapidly due to wind and weather, containing/booming the fluids to the required thickness to start and maintain a controlled burn is not…

I was under the impression that you shouldn’t begin a sentence with “Because.”

Can you shed any light on this for me?

Great question!

You can start a sentence with a conjunction – and, but, because etc. Typically, that ‘rule’ about not starting with a conjunction is a hangover from early school days and teachers who had it inculcated into them in their school days, possibly back to when Latin was the lingua franca.

I changed it to because because as has so many possible meanings (24, according to [Australian] Macquarie Dictionary). Because only has four meanings in Macquarie, two of which are colloquial and irrelevant to the context, and the other two are basically the same – ‘for the reason that’.

As far as business report writing goes, starting a sentence with And or But may be too casual. However, in our reports we start sentences with However (a good substitute for But), Although, While, Since, Therefore, etc. all the time – I put Because in the same category. I always check sentences starting with As, because that word has so many possible meanings, and will substitute something more appropriate to the context if necessary.

The Australian Style Manual (which, along with Macquarie, is one of our authorities) says this (p72-73):

‘Because’ and other subordinators to start a sentence

The idea that words like because, although, since and while cannot be used at the start of a sentence seems to arise out of a mistaken assumption that, because conjunctions join phrases or clauses together, they must have words on either side of them. This does not happen at the start of a sentence, hence this odd prescription. The reality is that a subordinating conjunction goes with the subordinate clause, wherever it is placed:

We notified the secretary because he is the person responsible.

Because he is responsible, we notified the secretary.

These perfectly grammatical sentences show the subordinating conjunction at two different points in the sentence, prefacing the explanatory clause (‘he is the person responsible’). Explanatory and other subordinate clauses (such as those with if and when) can certainly be used at the front of a sentence, and the conjunction will then be the first word.

Other discussions on this:


[Links last checked October 2015]


Get every new post delivered to your Inbox.

Join 451 other followers