Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Skip Microsoft Word 2007 grammar check for code

Tags:

ms-word

Do you know how to insert a "code block" in a Microsoft Word 2007 document so it will not be analyzed by the grammar checker? I do no want to turn it off for the whole documents, just for some sections.

Can I do this via a custom style?

like image 769
lemotdit Avatar asked Nov 04 '09 19:11

lemotdit


2 Answers

  1. Select the text that you want the spelling and grammar checker to ignore.

  2. On the Review tab, in the Proofing group, click Set Language.

  3. Select the Do not check spelling or grammar check box.

You can also create a special style that is based on the selected text:

  1. Right-click the selection, and then click Save Selection as a New Quick Style on the Styles shortcut menu.

  2. Give the style a name — for example, code — and then click OK.

like image 114
Nescio Avatar answered Sep 29 '22 09:09

Nescio


I done what the above guy said but created a macro:

  1. Highlight the text you want to strip of grammar checks
  2. Click the Macros (on the View ribbon)> Record macros > [give a name ] > Assign Macros to button > [Click the name you chose] > click add.
  3. Do what the Nescio (above) said (steps 1 to 3)
  4. Click macros > Stop Recording

Your button will be at the top of the page next to your floppy disc / save Icon

like image 25
Max Carroll Avatar answered Sep 29 '22 09:09

Max Carroll