Word: How to replace italicised words with underscores of same length?
August 3, 2018 1:17 PM   Subscribe

I'm preparing some quizzes that I'll use over a few months. I *will* forget the answers so I'd like to create an answer sheet and a test sheet. They take the form of fill-in-the-gaps

like this:

"The author of this question is _______."

I've been going through manually creating the answer sheet then redacting words to make the questions, but this is laborious in word and prone to error. Is there a way to have word automatically replace any italicised words with underscores of equivalent length?
posted by Hadrian to Computers & Internet (6 answers total)
 
Best answer: The exact way to do this varies by the version of Word you are using, but in the Find and Replace dialog box if you look for it you'll find that you can (a) use wildcard characters and (b) restrict the search by formatting.

The wild card for *any character* is ^?.

In Word 2016, in the Find and Replace dialog box, there should be a button that says "More >>". Click that, and you'll see a button at the bottom that says "Format". That'll ultimately allow you to select italics. Then the search should find any character that's italicized. You can replace each of those with "_".

Hope this helps!
posted by lmindful at 1:43 PM on August 3, 2018 [1 favorite]


You ought to be able to use wildcards and format search together to do this (searching on "*" and formatting Italic), but you probably shouldn't, as you've described it. You shouldn't be allowing your brain to rely on clues such as how many letters there are in a answer.
posted by praemunire at 1:46 PM on August 3, 2018


There's another way to do this. You can just select any piece of italicised text, then (this is Word 2010, but other versions should have the feature) right-click -> Styles -> Select Text with Similar Formatting.

This select all italicised text in the document.

You could then apply the 'Emphasis' style to all of the italicised text you've just selected. Then you can modify the 'Emphasis' style to have white text and a black underline (that's the the Font settings for the style). Then, to convert your document from test sheet to answer sheet, all you need to do is to modify the style properties for that style.

Of course, this latter presupposes that you're printing the sheets and not distributing them electronically, in which case the answers would be recoverable to a reader...
posted by pipeski at 2:25 PM on August 3, 2018 [4 favorites]


I know this wasn't part of your question, but replacing the literal characters with underscores will produce blanks of varying lengths. Savvy test-takers will notice this immediately and will very much use it to their advantage. If this concerns you, you should find another way to create the blanks.
posted by donnagirl at 4:45 PM on August 3, 2018 [3 favorites]


If you do the varying-size version, if this reference on wildcards is still up to date, you should be able to then wildcard search for '_{2,}' and replace every series of at least two underscores with a fixed-size set of underscores for every word.
posted by Sequence at 10:40 PM on August 3, 2018 [1 favorite]


Response by poster: Huge thanks for all your help here.
posted by Hadrian at 8:16 AM on August 9, 2018


« Older How can I easily tell if a Wordpress plugin update...   |   Help! Virus. Newer »
This thread is closed to new comments.