Archive for the ‘Software’ Category

h1

Word: Selected text won’t move

August 15, 2018

Here’s one I’ve encountered every so often, but have never figured out why—sometimes when I select a piece of text in a Word document, then try to drag it to another location (e.g. a different table cell; elsewhere in the paragraph), I can’t do it. Instead, I see a small black circle with a black diagonal line through it and the selected text won’t go where I want it to go. I have to copy the text, then paste it at the new location, instead of dragging and dropping it. It doesn’t happen every time, which of course it what makes it hard to figure out the cause.

I’ve now found out why, courtesy of one of my global colleagues on a Facebook group for editors—the reason it won’t drag to the new location is because the Cross Reference window is open! If you close that window, you can move the selected text. (Note: Other windows that can remain open while you’re working on a document may also result in this behaviour—I haven’t tested those.)

This situation is unlikely to happen to most Word users, because most have no use for cross-referencing. But power users and those working in large documents with lots of cross references may like to know that an open Cross Reference window is the reason you can’t move selected text.

h1

Word: The things you learn – scroll tabs on the ribbon

August 14, 2018

Just when I thought there wasn’t much new to learn about the Word for Office for Windows interface… (NOTE: I tested this technique in Word, Outlook, PowerPoint, and Excel, and it works the same in all of them, so it must be a Microsoft Office thing.)

Over on an editors’ Facebook group today, one of the members posted a trick that was new to her—it’s new to me too, but may well have been in Office for Windows ever since the ribbon interface came in with Office 2007.

That trick is quickly moving between tabs on the ribbon by hovering over one tab, then rolling the scroll wheel of your mouse. It’s another way to minimise wrist movements using a mouse.

Whether you go left to right through the tabs, or vice versa, depends on which way you roll the scroll wheel—roll it towards you and you go from left to right; roll it forward and you go from right to left. You can only roll to the first or last tab; further rolling doesn’t ‘wrap’ around the tabs.

 

h1

Word: Using EditTools to add multiple journal titles

August 10, 2018

This post is for me and anyone else who uses EditTools. I had to ask Rich Adin (the developer of EditTools) to help me understand how the Journal Manager worked (http://www.wordsnsync.com/journals.php). He was kind enough to point me in the right direction (and offer more information to this blog post below) and I’ve now got it working. Because it might be some months before I have to do this again, I’m writing up my instructions to prop up my dodgy memory!

Some caveats:

  • If you ALWAYS need your journal titles to end with punctuation (e.g. a comma [American Zoologist,] or a period [American Zoologist.]) in your reference list (as I do), you need to add that punctuation to the ‘correct’ form of the journal title in Journal Manager, otherwise that title won’t be found when you run the Journals function against your reference list. However, if you use various ending punctuation or no punctuation, it’s better to create a different dataset for each referencing style and then use the Multiple Entries window to automatically add the unpunctuated title (and its variations) to each dataset. Later, when you run the Journals macro, you choose what ending punctuation (if any) you want to find for that dataset and that reference list.
  • Don’t forget to add all forms of a journal title when you’re adding multiple entries—e.g. Am. Zool., Am Zool, and American Zoologist (if you’re putting punctuation at the end of the correct form), including the upper case variations.
  • Avoid clicking OK on the multiple entries window until you’ve added all variations for a journal title. (Actually, you can click OK, but you can only go back and edit the multiple entries list until you click Add or Cancel, or close the Journals Manager window.)
  • If the journal title begins with A, An, or The, don’t forget to specify that too, so you get The APPEA Journal as well as APPEA Journal.
  • From Rich Adin: It must always be remembered that macros are dumb tools. If you tell it to search for The J bAnnA, it will not find J Banna or J. bAnnA or any other variation. The journals macro will only find those variations that are in its dataset. Macros do precisely what they are told to do – nothing more and nothing less – which is why it is important to add variations. Consequently, if your author has used AmZool and the macro does not correct it to American Zoologist, you should immediately add AmZool to the dataset so that the next time AmZool is used, it gets changed to American Zoologist.
  • EditTools is an paid add-in for Microsoft Word for Windows; as far as I am aware it is not available for Word for Mac (unless you are working in Windows emulation software, such as Parallels).
  • One final note: The Journals macro is quite particular in other ways too. It searches for the title, which must be preceded by punctuation and a space and then followed by any punctuation variations you specify, followed by a space (a normal space, NOT a nonbreaking space) and then a number (e.g. [some word]. Am Zool, 23). If you have a journal title either not preceded by punctuation, or not followed by specified punctuation, a normal space, and then a letter character, the Journals macro will not find it (e.g it won’t find Am Zool, Volume 23 [because there’s no number after the space] or [some word] Am Zool, 23 [because there’s no punctuation before the journal title even though there’s a number after the space]). This is also why journal titles like Ecology or Science are only found as a journal title, not as a word in any title—the macro specifically looks for preceding punctuation and a number after the title. Without these limitations, the macro would change every instance of Ecology that matched a dataset entry, whether it was in an article or book title, an authoring body, or just a word in a sentence.

Here’s how to add multiple journal entries in EditTools v8.0 (there’s a YouTube video showing the process below these steps):

  1. Go to the EditTools tab in Word, then click the Mgr button next to Journals in the References group.
    This opens the Journal Manager window.
  2. Select the checkbox to Switch to enhanced Journals screen.
    This opens the Journal Manager screen. Any journals you’ve already entered will be listed in the large box; it will be blank if you haven’t entered any. (NOTE: Once you’ve switched to the enhanced view, that remains the default view unless you click to checkbox to change back to the standard view when you next re-open Journals Manager.)
  3. Critical step: Place your cursor in one of the Correct to fields on the right of this screen. If you only have one journal title file, then it will be the top one. (You can have up to five journal datasets [for different referencing styles or different clients], so add the term to each Correct to field to add the term for each of your datasets; leave the Correct to field blank if you don’t want to add a particular term to a particular dataset.)
  4. Type the name you want to use for the journal in the Correct to field—in my American Zoologist example, I want my reference list to use the full title followed by a comma, not an abbreviated title. So I type American Zoologist, (i.e. with a trailling comma) in that top box. I add a comma because when I use EditTools to scan for journal titles, I want it to find the correctly entered ones and to correct the incorrect ones (e.g. American Zoologist. with a period).
  5. Click Multiple Entries to open the Multiple Journal Name Entry screen, which is where you enter the title’s variations, such as abbreviated titles.
  6. In the Text to Add field, type the first variation of the journal title, select the check boxes for Ignore punctuation… and Add UPPER CASE, and leave all the Trailing Punctuation checkboxes set to the defaults. In the example below, I typed Am. Zool as the variation I want EditTools to correct to American Zoologist, if it finds it in my reference list.
  7. Click Add. The top part of the screen populates with all the variations of the Text to Add you entered, including all the trailling punctuation and upper case, if you checked those boxes.
  8. Repeat steps 6 and 7 for all other variations of the journal title—in my example, I added Am Zool then American Zoologist to get all variations of punctuation and case for each title variations. You may have more or fewer alternative titles to add. Make sure you select the checkboxes and click Add for each one. You could well end up with more than 100 variations for one journal title! (in the example above, I could also make variations for Amer ZoolAmer ZoologistAmerican Zool, plus more for each of these with punctuation after the first word.)
  9. When you’ve finished adding title variations, click OK to return to the Journal Manager screen. All the variations you just added are listed at the bottom of the main box on that screen. (Don’t worry about that—they will re-sort themselves into alphabetical order after you close Journal Manager and re-open it.)
  10. Click Save.
  11. Repeat steps 3 to 10 for all other journal titles and their variations you want to add.
  12. When you have finished, click Save and Close.

A word about what cyan and green in the box mean: cyan indicates an incorrect form of the title; green indicates a correct form. Lines with | cyan -> [title] tell you that if that form is found, it will be changed to the form listed after the -> (and highlighted in cyan in your Word document) when you run Journals from the EditTools ribbon. Green highlighting shows correct entries, and you won’t need to check those.

YouTube video of the process (1 min 27 secs; video only, no audio):

h1

Word: Add a character to all items in a long list, and style it in a colour

July 27, 2018

Here was a tricky one posed by my husband first thing this morning. He had a very long column in a table (some 2750+) rows, in which he had some sort of code, like a product identifier. Fortunately, the codes were all the same — they were all K-xxxx, where ‘xxxx’ was a 4-digit number (e.g. K-1234, K-5432, etc.).

He wanted to add a zero immediately after the hyphen. Easy enough. But he wanted this zero character to be blue! Hmmm… (and no, I have no idea why! Update: He had a list of catalogue numbers, but when the company used up all the 4-digit numbers, they changed to 5-digit numbers. To sort them correctly by catalogue number in Word, he needed to add a leading 0 to the 4-digit ones, but he wanted to show that the 0 wasn’t part of the original number, thus the colour.)

After a few minutes of testing I achieved what he wanted. I had to do three find and replace passes, with one of them a wildcard find/replace — the first pass added the 0, the second changed the colour of the hyphen and its trailling zero to blue, and the third changed the colour of the hyphen back to black, leaving just the 0 after the hyphen in blue text.

NOTE: If you’re doing something like this on your own document, either work on a COPY until you’ve refined the procedure and know you won’t inadvertently replace something you shouldn’t have, OR at the ‘Replace All’ steps below, click ‘Replace’ instead, followed by ‘Find Next’. You will have many more clicks to do, but it’s a safer option.

Here’s what I did:

First pass – add a zero after the hyphen:

  1. Open the Find/Replace window (Ctrl+H).
  2. In the Find What field, type K-
  3. In the Replace With field, type K-0
  4. Select the list (or column in a table) you want to apply this change to
  5. Click Replace All. This adds a zero after the K-, so you end up with codes like K-01234, K-05432, etc.
  6. Leave the Find and Replace window open.

Second pass – make the hyphen and the zero another colour:

  1. For the second pass, click outside the selection to position the cursor away from it (I had to do this because as soon as I entered the wildcard string for the colour, ALL the selected text changed to blue, without me even clicking Replace All — very strange).
  2. In the Find/Replace window, click More.
  3. Select the Use wildcards checkbox.
  4. In the Find What field, type (-)(0) (there are NO spaces in this string).
  5. In the Replace With field, type \1\2 (there are NO spaces in this string).
  6. With your cursor still in the Replace With field, click Format.
  7. Select Font.
  8. Choose a colour from the Font color drop down.
  9. Click OK.
  10. Check the Replace With field — it should have Font color: <name of colour> below the field. The only thing below the Find What field should be Use wildcards. If you have something different, repeat these steps, and make sure you follow Step 6 exactly.
  11. Select the list (or column) again.
  12. Click Replace All. This changes the hyphen and trailling zero to the colour you selected.
  13. Leave the Find and Replace window open.

Third pass – remove the colour from the hyphen:

  1. For the third and final find and replace pass, click outside the selection to position the cursor away from it. Don’t forget to do this!
  2. Clear the Use wildcards checkbox.
  3. In the Find What field, delete the existing characters, then type a hyphen.
  4. In the Replace With field, delete the existing characters, then type a hyphen.
  5. With your cursor still in the Replace With field, click Format, select Font, then in the Font Color drop-down box, select Automatic (or another font colour).
  6. Select the list (or column) again.
  7. Click Replace All. This changes the hyphen colour to the colour you selected in Step 5.

 

h1

Word: Wildcard find and replace for numbers inside parentheses

July 22, 2018

In a comment on another post (https://cybertext.wordpress.com/2015/07/14/word-wildcard-find-and-replace-for-numbers-and-trailing-punctuation/), AVi asked if there was a way to find percentage numbers (e.g. 56%) that were inside parentheses, and replace them with the same number but without the parentheses — i.e. (56%) becomes 56%.

There is, but it’s a bit trickier than usual because parentheses are also special characters in Word’s find/replace lexicon—these have to be ‘escaped’ for Word to treat them as normal characters and not as special characters.

In figuring this out, I also took into account that there might be single numerals (e.g 4%), triple numerals (e.g. 125%), and numerals with one or more decimals (e.g. 75.997%).

Here’s what I came up with that worked for all those scenarios:

  1. Press Ctrl+H to open the Find and Replace dialog.
  2. Click More, then select the Use wildcards check box.
  3. In Find What, type: ([\(])([0-9]*%)([\)])
  4. In Replace With, type: \2
  5. Click Find Next, then click Replace once the first is found. Once you’re happy that it works, repeat until you’ve replaced them all.

What the find and replace ‘codes’ mean:

The three elements (each is enclosed in parentheses) of the Find are:

  1. ([\(]) — You need to find a specific character (the opening parenthesis), so you need to enclose it in parentheses. However, because parentheses are special wildcard characters in their own right, you need to tell Word to treat them as normal text characters and not as special characters, so you put in a backslash ‘\‘ (also known as an ‘escape’ character) before the (, AND surround this string in square brackets [ ] (otherwise, it won’t work).
  2. ([0-9]*%) — The [0-9] represents any number from 0 to 9; the * represents any more characters immediately after that number (more numbers, or a decimal point), thus not limiting the find to only single digit numbers; and the % symbol says this string of numbers found must finish with that symbol. This finds numbers like 2%, 25%, 283%, 25.4%, etc.
  3. ([\)]) — You need to find the closing parenthesis, so you need to enclose it in parentheses. However, because the closing parenthesis is a special wildcard character in its own right, you need to tell Word to treat it as a normal text character and not as a special character, so you ‘escape’ it with a backslash ‘\‘ before the ), then surround that string in square brackets.

There are no spaces preceding or trailing any of these elements, or in between them, so if you copy the code from this blog post, get rid of any preceding spaces otherwise it won’t work .

For the Replace: \2 — Tells Word to replace the second element of the Find with what was in the Find (i.e. a number followed by a % symbol) .

AVi: I hope this solves your problem. Donations to keeping this blog ad-free gratefully accepted (see the link at the top right of the page).

 

h1

Word: Finding duplicate words

July 11, 2018

I had a long list (57 pages!) of Latin species names, sorted into alphabetical order. I’d separated the words so that there was only one word on each line. My next task was to go through and remove all the duplicates (i.e. a word immediately followed by the same word) so I could add the final list to my custom dictionary for species in Microsoft Word. I started doing it manually—it’s easy enough to find duplicates when the words are familiar, but for Latin words, my brain just wasn’t coping well and I was missing subtle differences like a single or double ‘i’ at the end of a word. There had to be a better way…

And there is! Good old Dr Google came to the rescue, and with a bit of fiddling to suit my circumstances (one word on each line), I got a wildcard find and replace routine to find the duplicates.

NOTE: DO NOT do a ‘replace all’ with this, in case Word makes unwanted changes. In my case it didn’t treat the second word as a whole word for matching purposes (e.g. it thought banksi, banksia, and banksii were duplicates). Even though I had to skip some of these, it was still worth it to automate much of the process. Another caveat—if you have several lines of the same word, each pair will be found, but you’ll have to run the find several times to get them all. Much better to move your cursor into Word and delete the excess multiple duplicates when you find them. You may still have to do a couple of passes over the document, but the heavy lifting will have been done for you.

Here’s what I did to get it work:

  1. Press Ctrl+H to open the Find and Replace window.
  2. Click More, then select the Use Wildcards checkbox.
  3. In the Find What field, type (<*>)^013\1 (there are no spaces in this string).
  4. In the Replace With field, type \1 (there are no spaces in this string either).
  5. Click Find Next.
  6. When a pair of matching whole words is found, click Replace. NOTE: If the second word is only a partial match for the first word, click Find Next.
  7. Repeat steps 5 and 6 until you’re satisfied you’ve found them all.

How this works:

  • (<*>) is the first element (later represented by \1) of the find. The angle brackets specify the start and end of a word, and the ‘word’ is anything (represented by the *). In other words, you’re looking for a whole ‘word’ of any length and made up of any characters (including numbers).
  • ^013 is the paragraph marker at the end of the line. In my situation, each word was on its own line with a paragraph mark at the end of the line. If you don’t have this situation, leave this out and replace it with a space (two repeated words in the same line are separated by a space). NOTE: Normally you can find a paragraph mark in a Find with ^p, but not with a wildcard Find—you have to use ^013.
  • \1 is the first element. In the Find, it means the duplicate of whatever was found by (<*>); in the Replace, it means replace the duplicated word with the first word found.

 

h1

Word: Find all words with two or more capital letters

July 9, 2018

Someone in one of my online editing groups wanted to find all the acronyms and initialisms in their document—any word comprising two or more capital (‘cap’) letters (e.g. AB, CDEF, GHIJK, etc.). They wanted a command that would find each one so they could check it (possibly against a glossary), then click Find Next to jump to the next one.

Wildcards to the rescue!

Here’s how:

  1. Press Ctrl+H to open the Find and Replace window.
  2. Click the Find tab (we only want to find these, no replace them with anything else).
  3. Click More to show further options.
  4. Select the Use wildcards checkbox.
  5. In the Find what field, type: <[A-Z]{2,}>
  6. Click Find next to find the first string of two or more caps.
  7. Keep clicking Find next to jump to the next string of two or more caps.

How this works:

  • The opening and closing arrow brackets (< and >) specify that you want a single whole word, not parts of a word. Without these, you would find each set of caps (e.g. in the string ABCDEF, you would find ABCDEF, then BCDEF, then CDEF, then DEF, then EF, before moving on to the next set of caps).
  • [A-Z] specifies that you want a range (the [ ] part) of caps that fall somewhere in the alphabet (A-Z). If you only wanted capped words that started with, say, H through to M, then you’d change the range to [H-M] and all other capped words starting with other letters would be ignored.
  • {2,} means you want to find capped words with at least two letters in the specified range (i.e. A-Z). If you only wanted to find two- and three-letter capped words, then you’d change this to {2,3}, and all capped word of four or more letters would be ignored. By not specifying a number after the comma, the ‘find’ will find capped words of any length containing at least two letters.