Skip to content

Microsoft Word =rand Automatically Creates Text

April 7, 2007

Microsoft Word has a little known feature that inserts the following text into your document:

The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.

“The quick brown fox jumps over the lazy dog” is a pangram (a phrase that uses all the letters of the alphabet) that has been used to test typewriters and computer keyboards because it is nicely coherent and short. Read more about “The quick brown fox jumps over the lazy dog” (Wikipedia).

To insert this text into your Microsoft Word, simply type “=rand()” (without the quotation marks), and viola!

By default, the sample text contains three paragraphs, with each paragraph containing five sentences. You can control how many paragraphs and sentences appear by adding numbers inside the parentheses.

The =rand() function has the following syntax

=rand(p,s)

where p is the number of paragraphs and s is the number of sentences that you want to appear in each paragraph.

Examples:

=rand(1) inserts one five-sentence paragraph of text

=rand(1,1) inserts one one-sentence paragraph of text.

=rand(1,2) inserts one two-sentence paragraph of text

=rand(2) inserts two five-sentence paragraphs of text

=rand(2,1) inserts two one-sentence paragraphs of text

=rand(10) inserts 10 five-sentence paragraphs of text

=rand(10,1) inserts 10 one-sentence paragraphs of text

=rand(10,10) inserts 10 ten-sentence paragraphs of text

Note When you omit the second number, the default is five sentences of text. The maximum number that can be used inside the parenthesis is 200 (this number may be lower depending on the number of paragraphs and sentences specified).

Related Posts.