You can apply text formatting to field results in the same way you format any text in your document (for example, bold, underlined, and so on): select the field code or field result, and apply formatting.
Note: If you update a field, any text formatting that you applied to the field results may be lost. To retain the formatting, include the * MERGEFORMAT switch in the field code. When you insert fields by using the Field dialog box, the * MERGEFORMAT switch is included by default.
In addition to text formatting, you can control the format of field results at the field level, with general switches that determine how data in the field is displayed. Depending on the field code, there are three types of general switches:
-
Format switch
-
Numeric format switch
-
Date-Time format switch
The Format field switch (*) defines how to display field results. The format instructions determine the following:
-
The use of uppercase and lowercase letters
-
Number formats — for example, whether 9 is displayed as ix (roman numerals) or ninth (ordinal text)
-
character formats
Format switches also retain a field result’s formatting when the field is updated.
The following is a list of switches and the items that they capitalize:
-
* Caps This switch capitalizes the first letter of each word. For example, { FILLIN «Type your name:» * Caps } displays Luis Alverca even if the name is typed in lowercase letters.
To select this option in the Field Options dialog box, click Title case.
-
* FirstCap This switch capitalizes the first letter of the first word. For example, { COMMENTS * FirstCap } displays Weekly report on sales.
To select this option in the Field Options dialog box, click First capital.
-
* Upper This switch capitalizes all letters. For example, { QUOTE «word» * Upper } displays WORD.
To select this option in the Field Options dialog box, click Uppercase.
-
* Lower This switch capitalizes none of the result; all letters are lowercase. For example, { FILENAME * Lower } displays weekly sales report.doc.
This switch has no effect if the entire field that contains the switch is formatted as small capital letters.
To select this option in the Field Options dialog box, click Lowercase.
The following is a list of number switches and their results:
-
*alphabetic This switch displays results as alphabetic characters. The result has the same case as the word «alphabetic» in the field code. For example, { SEQ appendix * ALPHABETIC } displays B (instead of 2), and { SEQ appendix * alphabetic } displays b.
To select this option in the Field Options dialog box, click a, b, c,.
-
*Arabic This switch displays results as Arabic cardinal numerals. For example, { PAGE * Arabic } displays 31.
Notes:
-
If the Number format setting in the Page Number Format dialog box is not Arabic, this switch overrides the Number format setting.
-
For page numbers only, there is also an ArabicDash format, which displays results as Arabic cardinal numbers surrounded by hyphen characters. For example, { PAGE * ArabicDash } displays — 31 —.
To select this option in the Field Options dialog box, click 1, 2, ,3, ….
-
-
*CardText This switch displays results as cardinal text. The result is formatted in lowercase letters unless you add a format switch to specify a different capitalization. For example, { = SUM(A1:B2) * CardText } displays seven hundred ninety, and { = SUM(A1:B2) * CardText * Caps } displays Seven Hundred Ninety.
To select this option in the Field Options dialog box, click One, Two, Three.
-
*DollarText This switch displays results as cardinal text. Word inserts and at the decimal place and displays the first two decimals (rounded) as Arabic numerators over 100. The result is formatted in lowercase letters unless you add a format switch to specify a different capitalization. For example, { = 9.20 + 5.35 * DollarText * Upper } displays FOURTEEN AND 55/100.
To select this option in the Field Options dialog box, click Dollar Text.
-
*Hex This switch displays results as hexadecimal numbers. For example, { QUOTE «458» * Hex } displays 1CA.
To select this option in the Field Options dialog box, click hex ….
-
*OrdText This switch displays results as ordinal text. The result is formatted in lowercase letters unless you add a format switch to specify a different capitalization. For example, { DATE @ «d» * OrdText } displays twenty-first, and { DATE @ «d» * OrdText * FirstCap } displays Twenty-first.
To select this option in the Field Options dialog box, click First, Second, Third, ….
-
*Ordinal This switch displays results as ordinal Arabic numerals. For example, { DATE @ «d» * Ordinal } displays 30th.
To select this option in the Field Options dialog box, click 1st, 2nd, 3rd.
-
*roman This switch displays results as Roman numerals. The result has the same case as the word «roman» in the field code. For example, { SEQ CHAPTER * roman } displays xi, and { SEQ CHAPTER * ROMAN } displays XI.
To select this option in the Field Options dialog box, click I, II, III,.
The following are character formatting switches and their results:
-
*Charformat This switch applies the formatting of the first letter of the field name to the entire result. The result of the following example has bold formatting because the R in REF is bold.
{ REF chapter2_title * Charformat } displays Whales of the Pacific in bold text.
To add this switch, type it in the field code or in the Field codes box in the Field dialog box.
-
*MERGEFORMAT This switch applies the formatting of the previous result to the new result. For example, if you select the name displayed by the field { AUTHOR * MERGEFORMAT } and apply bold formatting, Word retains the bold formatting when the field is updated to display a new author name.
When you insert fields by using the Field dialog box , the *MERGEFORMAT switch is included by default. You can turn this option off by clearing the Preserve formatting during updates check box in the Field dialog box.
The Numeric format switch (#) specifies the display of a numeric result.
For example, the switch # $,0.00 in { = SUM(ABOVE) # $,0.00 } displays a result such as «$4,455.70.» If the result of a field is not a number, this switch has no effect.
Note: Quotation marks are not required around simple numeric formats that do not include spaces — for example, { MarchSales # $,0.00 }. For more complex numeric formats and those that include text or spaces, enclose the numeric format in quotation marks, as shown in the following examples. Word adds quotation marks to numeric format switches if you insert a field by using the Field dialog box or the Formula command in the Data group of the Layout tab (Table Tools contextual tab).
Combine the following format items to build a numeric format switch:
-
0 (zero) This format item specifies the requisite numeric places to display in the result. If the result does not include a digit in that place, Word displays a 0 (zero). For example, { = 4 + 5 # 00.00 } displays 09.00.
-
# This format item specifies the requisite numeric places to display in the result. If the result does not include a digit in that place, Word displays a space. For example, { = 9 + 6 # $### } displays $ 15.
-
x This format item drops digits to the left of the «x» placeholder. If the placeholder is to the right of the decimal point, Word rounds the result to that place. For example:
{ = 111053 + 111439 # x## } displays 492.
{ = 1/8 # 0.00x } displays 0.125.
{ = 3/4 # .x } displays .8. -
. (decimal point) This format item determines the decimal point position. For example, { = SUM(ABOVE) # $###.00 } displays $495.47.
Use the decimal symbol that is specified as part of the regional settings in Control Panel.
-
, (digit grouping symbol) This format item separates a series of three digits. For example, { = NetProfit # $#,###,### } displays $2,456,800.
Use the digit grouping symbol that is specified as part of the regional settings in Control Panel.
-
— (minus sign) This format item adds a minus sign to a negative result or adds a space if the result is positive or 0 (zero). For example, { = 10 — 90 # -## } displays -80.
-
+ (plus sign) This format item adds a plus sign to a positive result, a minus sign to a negative result, or a space if the result is 0 (zero). For example, { = 100 — 90 # +## } displays +10, and { = 90 — 100 # +## } displays -10.
-
%, $, *, and so on This format item includes the specified character in the result. For example, { = netprofit # «##%» } displays 33%.
-
«example formatting for positive; negative» This format item specifies different number formats for positive and negative results, separated by a semicolon. For example, if the bookmark Sales95 is a positive value, the field { Sales95 # «$#,##0.00;-$#,##0.00» } displays the value with regular formatting — for example, «$1,245.65». A negative value is displayed with bold formatting and a minus sign — for example, -$ 345.56.
-
«example formatting for positive; negative; zero» This format item specifies different number formats for a positive result, a negative result, and a 0 (zero) result, separated by semicolons. For example, depending on the value of the Sales95 bookmark, { Sales95 # «$#,##0.00;($#,##0.00);$0» } displays positive, negative, and 0 (zero) values as follows: $1,245.65, ($ 345.56), $0.
-
‘text’ This format item adds text to the result. Enclose the text in single quotation marks. For example, { = { Price } *8.1% # «$##0.00 ‘is sales tax’ » } displays $347.44 is sales tax.
-
`numbereditem` This format item displays the number of the preceding item that you numbered by using the Caption command (References tab, Captions group) or by inserting a SEQ field. Enclose the item identifier, such as «table» or «figure,» in grave accents (`). The sequential number is displayed in Arabic numerals. For example, { = SUM(A1:D4) # «##0.00 ‘is the total of Table’ `table`» } displays 456.34 is the total of Table 2.
The Date-Time format switch (@) specifies how to display the date or time.
For example, the switch @ «dddd, MMMM d, yyyy» in the field { DATE @ «dddd, MMMM d, yyyy» } displays «Friday, November 23, 2019.» Combine the following date and time instructions — day (d), month (M), and year (y); hours (h) and minutes (m) — to build a date-time format. You can also include text, punctuation, and spaces.
Month (M)
The letter M must be uppercase to distinguish months from minutes.
-
M This format item displays the month as a number without a leading 0 (zero) for single-digit months. For example, July is 7.
-
MM This format item displays the month as a number with a leading 0 (zero) for single-digit months. For example, July is 07.
-
MMM This format item displays the month as a three-letter abbreviation. For example, July is Jul.
-
MMMM This format item displays the month as its full name.
Day (d)
The letter d displays the day of the month or the day of the week. The letter d can be either uppercase or lowercase.
-
d This format item displays the day of the week or month as a number without a leading 0 (zero) for single-digit days. For example, the sixth day of the month is displayed as 6.
-
dd This format item displays the day of the week or month as a number with a leading 0 (zero) for single-digit days. For example, the sixth day of the month is displayed as 06.
-
ddd This format item displays the day of the week or month as a three-letter abbreviation. For example, Tuesday is displayed as Tue.
-
dddd This format item displays the day of the week as its full name.
Year (y)
The letter y displays the year as two or four digits. The letter y can be either uppercase or lowercase.
-
yy This format item displays the year as two digits with a leading 0 (zero) for years 01 through 09. For example, 1999 is displayed as 99, and 2006 is displayed as 06.
-
yyyy This format item displays the year as four digits.
Hours (h)
A lowercase h bases time on the 12-hour clock. An uppercase H bases time on the 24-hour, or military, clock; for example, 5 P.M. is displayed as 17.
-
h or H This format item displays the hour without a leading 0 (zero) for single-digit hours. For example, the hour of 9 A.M. is displayed as 9.
-
hh or HH This format item displays the hour with a leading 0 (zero) for single-digit hours. For example, the hour of 9 A.M. is displayed as 09.
Minutes (m)
The letter m must be lowercase to distinguish minutes from months.
-
m This format item displays minutes without a leading 0 (zero) for single-digit minutes. For example, { TIME @ «m» } displays 2.
-
mm This format item displays minutes with a leading 0 (zero) for single-digit minutes. For example, { TIME @ «mm» } displays 02.
Seconds (s)
-
s This format item displays seconds without a leading 0 (zero) for single-digit seconds. For example { TIME @ “s” displays 5.
-
ss This format item displays seconds with a leading 0 (zero) for single-digit seconds For example { TIME @ “ss” displays 05.
A.M. and P.M. (AM/PM)
This displays A.M. and P.M. To change the A.M. and P.M. symbols for Microsoft Windows, change the regional settings in Control Panel.
-
am/pm or AM/PM This format item displays A.M. and P.M. as uppercase. For example, { TIME @ «h AM/PM» } and { TIME @ «h am/pm» } display 9 AM or 5 PM.
-
‘text’ This format item displays any specified text in a date or time. Enclose the text in single quotation marks. For example, { TIME @ «HH:mm ‘Greenwich mean time’ » } displays 12:45 Greenwich mean time.
-
character This format item includes the specified character in a date or time, such as a : (colon), — (hyphen), * (asterisk), or space. For example, { DATE @ «HH:mm MMM-d, ‘yy» } displays 11:15 Nov-6, ’99.
-
`numbereditem` This format item includes in a date or time the number of the preceding item that you numbered by using the Caption command in the Captions group (References tab), or by inserting a SEQ field. Enclose the item identifier, such as table or figure, in grave accents (`). Word displays the sequential number in Arabic numerals. For example, { PRINTDATE @ «‘Table’ `table` ‘was printed on’ M/d/yy» } displays Table 2 was printed on 9/25/02.
Note: Quotation marks are not required around simple date-time formats that do not include spaces or text — for example, { DATE @ MM/yy }. For more complex date-time formats and those that include spaces or text, enclose the entire date-time format in quotation marks, for example, { DATE @ «dddd MMMM d, yyyy’, at’ h:mm» }. Word adds quotation marks to date-time format switches if you insert a field by using the Date and Time command in the Text group of the Insert tab or the Field dialog box.
You can use Word to create interactive digital forms that other people can fill out on their computers before printing or sending them back to you. It takes a little preparation but keeps you from having to decipher messy handwriting! Some of the tools you will use when creating a form include:
- Templates: Forms are normally saved as templates so that they can be used again and again.
- Content controls: The areas where users input information in a form.
- Tables: Tables are often used in forms to align text and form fields, and to create borders and boxes.
- Protection: Users can complete the form fields without being able to change the form’s text and/or design.
Show the Developer Tab
Before you can create a form, you’ll need to turn on the Developer tab to get access to the advanced tools.
- Click the File tab.
- Select Options.
The Word Options window opens.
- Click the Customize Ribbon tab on the left.
The column on the right controls which ribbon tabs are enabled.
- Check the Developer check box.
- Click OK.
The Developer tab now appears on the ribbon. In addition to advanced tools for macro recording, add-ins, and document protection, we now have access to form controls.
Create a Form
Once you’ve enabled the Developer tab, and created the layout and structure of the form, you can start adding form fields to your document with Content Controls.
- Place the text cursor where you want to insert the form field.
- Click the Developer tab on the ribbon.
The Controls group contains the different kinds of content controls you can add to a form, as well as the toggle button for Design Mode.
- Click the Design Mode button in the controls group.
While Design Mode is active, controls you insert won’t be active, so clicking a check box to move it around won’t also check it. You can also customize placeholder text for some controls.
- Click a Content Control buttons to insert the selected type of control.
The content control is inserted.
Select a form field and click the Properties button on the ribbon to edit a control’s options. Depending on the type of control you’ve inserted, you can change its appearance, set up the options in a list, or lock the control once edited.
- When you’re done, click the Design Mode button again to exit Design Mode.
You leave Design Mode, and the content controls that you’ve inserted can now be used.
Types of Form Controls
There are many different types of form controls you can add to a form that will allow people to add different types of responses.
Finalize a Form
When you’re ready to distribute a form so others can fill it out, you can restrict the form so that content controls cannot be removed or changed by those filling it out.
- Click the Restrict Editing button on the Developer tab.
The Restrict Editing pane appears on the right.
- Check the Editing restrictions check box.
- Click the Editing restriction list arrow.
- Select Filling in forms.
When this option is enabled, the only change that anyone else can make to this document is the filling in of form fields. They won’t be able to move, delete, or edit the fields themselves until protection is turned off.
- Click the Yes, Start Enforcing Protection button.
A password is not required to start enforcing protection, but you can add one if you’d like to prevent just anyone from turning this protection off.
- Enter a password (optional), then click OK.
The document is now restricted, and anyone you send it to will only be able to fill in the forms.
FREE Quick Reference
Click to Download
Free to distribute with our compliments; we hope you will consider our paid training.
How to Automate Microsoft Word by Inserting and Updating Fields
by Avantix Learning Team | Updated March 14, 2021
Applies to: Microsoft® Word® 2010, 2013, 2016, 2019, 2021 or 365 (Windows)
You can create dynamic components in your Word documents by inserting and updating fields. When you use built-in commands and features, many Word fields are inserted automatically. For example, if you insert a dynamic date or page numbering, Word inserts fields in your document. Essentially, fields are variables that are inserted using field codes. Update your fields and your document updates automatically!
You normally see the result of a field or variable rather than the codes but you can display field codes. In this article, we’ll discuss inserting and updating fields but, as you get more comfortable with fields, you can edit the field codes directly and even apply different types of formatting using switches.
Note: If you are working with fields in Microsoft Word, you will be using quite a few function keys (such as F9). On some laptops, you will need to press the Fn key on your keyboard to enable your function keys. For example, instead of pressing F9, you would press Fn + F9.
Recommended article: 21 Microsoft Word Formatting Shortcuts for Faster Formatting
Do you want to learn more about Microsoft Word? Check out our virtual classroom or live classroom Word courses >
Where is the Insert Field command?
The Insert Field command is hidden in the Ribbon so it’s a bit difficult to find.
To access it, you’ll need to click the Quick Parts button on the Insert tab. The Field command appears in the drop-down menu as follows:
The Field dialog box appears as follows in Microsoft Word:
Insert a field using the Field dialog box
To insert a field using the Field dialog box:
- Navigate to the location in the Word document where you want to insert a field.
- Click the Insert tab in the Ribbon.
- Click Quick Parts. A drop-down menu appears.
- Select Field. A dialog box appears.
- In the list of Field names, select a field. You can filter the list by clicking the down arrow in the Categories list and selecting a category first.
- Under Field properties, select any properties or options you want.
- To see the codes for a particular field in the Field box, click Field Codes. For some fields, this button is clicked by default.
- Ensure that Preserve Formatting During Updates is checked so that formatting you apply is not removed when the fields are updated.
- Click OK. The field is inserted into the document.
- Format the field results by applying text formatting to the field using the Home tab in the Ribbon.
View or hide field codes
You can view or hide field codes in your document by pressing Alt + F9. Field codes appear between braces or curly brackets { }.
When you view field codes in your document, fields appear as follows:
{ FIELD NAME Properties Optional switches }
- FIELD NAME is the name that appears in the list of field names in the Field dialog box.
- Properties are any instructions or parameters that are used in a particular field. Not all fields have properties or parameters and, in some fields, parameters are required.
- Optional switches are any optional settings that are available for some fields. Switches are another way of formatting specific fields.
You cannot insert a field by typing field code braces or curly brackets on your keyboard. To insert field code braces, press Ctrl + F9 to insert the braces and then you can type the remainder of the field using the correct syntax.
Edit a field in the Field dialog box
To edit a field in the Field dialog box:
- Right-click the field and then click Edit Field. A dialog box appears.
- Change the field properties and options.
- Click OK.
For some fields, you must display the field code first to edit the field. To display all the field codes in the document, press Alt + F9. Be sure to hide the field codes later by pressing Alt + F9 again.
Some fields are edited in their own dialog boxes instead of in the Field dialog box. For example, if you right-click a hyperlink and then click Edit Hyperlink, the Edit Hyperlink dialog box appears.
Highlight fields with grey shading
Fields can also be highlighted with grey shading to make them more visible in the document. Normally, when you click in a field, it appears with grey shading.
To change the shading settings for fields:
- Click the File tab in the Ribbon.
- Click Options. A dialog box appears.
- Click Advanced in the categories on the left.
- Under Show document content, in the Field shading list, select Always, Never or When selected (the default setting).
- Click OK.
Below is the Options dialog box:
Update fields
By default, Word should automatically update fields when a document is opened. Many fields are also updated automatically when you go to Print Preview (click the File tab and then click Print). If you prefer, you can update fields manually.
To update a field manually, right-click the field and then click Update Field or press F9.
To update all fields manually in the main body of a document, press Ctrl + A to select all and then press F9.
Some fields in headers, footers or text boxes must be updated separately. Click in the header, footer or text box, press Ctrl + A to select all and then press F9. Page fields (which display page numbering) do not need to be updated manually (they update when you go the Print Preview).
Lock fields
You can also lock fields to prevent automatic updating of the field. To lock a field so that field results are not updated, click the field, and then press Ctrl + F11.
To unlock a field so that field results can be updated, click the field, and then press Ctrl + Shift + F11.
Subscribe to get more articles like this one
Did you find this article helpful? If you would like to receive new articles, JOIN our email list.
More resources
How to Insert a Line in Word (3+ Ways)
Microsoft Teams Keyboard Shortcuts (40+ Shortcuts)
How to Keep Text Together in Microsoft Word (Paragraphs, Lines or Words)
How to Create a Table of Contents in Word (Insert, Format and Update a TOC)
10+ Great Microsoft Word Navigation Shortcuts to Move Around Quickly in Your Documents
Related Courses
Microsoft Word: Intermediate / Advanced
Microsoft Word: Designing Dynamic Word Documents Using Fields
Microsoft Word: Long Documents Master Class
Microsoft Word: Accessible Word Documents
Microsoft PowerPoint: Intermediate / Advanced
VIEW MORE COURSES >
Our instructor-led courses are delivered in virtual classroom format or at our downtown Toronto location at 18 King Street East, Suite 1400, Toronto, Ontario, Canada (some in-person classroom courses may also be delivered at an alternate downtown Toronto location). Contact us at info@avantixlearning.ca if you’d like to arrange custom instructor-led virtual classroom or onsite training on a date that’s convenient for you.
Copyright 2023 Avantix® Learning
Microsoft, the Microsoft logo, Microsoft Office and related Microsoft applications and logos are registered trademarks of Microsoft Corporation in Canada, US and other countries. All other trademarks are the property of the registered owners.
Avantix Learning |18 King Street East, Suite 1400, Toronto, Ontario, Canada M5C 1C4 | Contact us at info@avantixlearning.ca
When you create a merge field in Microsoft Word
(see Creating a WordWriter Template), you can
apply formatting to the field. For example, you can set a merge field’s
format to «Uppercase» to display the field’s value in uppercase letters.
WordWriter supports most text, date, and time formats available in Microsoft
Word.
- General Text Formatting Options
- Date and Time Formatting Options
- Formatting Options Not Supported in WordWriter 1.0
This section explains how to apply special merge field formatting.
You can apply all standard formatting (bold, italic, underline, etc.)
to merge fields from Word’s Format menu or toolbar.
General Text Formatting Options
The Field dialog opens when you add a new merge field to
a template. To open the dialog for an existing merge field,
right-click the field and select Edit Field…
The following text formatting options can be set
|
The Field Dialog in Microsoft Word 2002 (XP) |
WordWriter 1.0 does not support the following formatting
options: Mapped field, Vertical formatting, and NumberedItem.
To set a merge field’s formatting to Uppercase, Lowercase, Title case, or
First capital using the Field dialog:
- The Field dialog opens automatically when you insert a new merge field.
If you are formatting an existing merge field, right-click the merge field and
select Edit Field… - From the Format list select a format. For example, select Uppercase.
To display text before and/or after a merge field value:
- The Field dialog opens automatically when you insert a new merge field.
If you are formatting an existing merge field, right-click the merge field and
select Edit Field… - Check Text to be inserted before and/or Text to be inserted after.
- In the Text Before text box, enter a phrase to display before the merge field
value, and/or, in the Text After text box, enter a phrase to display after the
merge field value.
You can also set these formatting options by entering special codes in the
merge field. To view and edit a merge field’s field codes, right-click the field
and select Toggle Field Codes. A field without special formatting looks like
this:
{MERGEFIELD FieldName}
Format | Field Codes | Example |
---|---|---|
Uppercase | {MERGEFIELD FieldName * Upper} | {MERGEFIELD ProductName * Upper} |
Lowercase | {MERGEFIELD FieldName * Lower} | {MERGEFIELD ProductName * Lower} |
First capital | {MERGEFIELD FieldName * FirstCap} | {MERGEFIELD ProductName * FirstCap} |
Title case | {MERGEFIELD FieldName * Caps} | {MERGEFIELD ProductName * Caps} |
Text Before | {MERGEFIELD FieldName b «Text to insert before«} | {MERGEFIELD OrderDate b «Order Date: «} |
Text After | {MERGEFIELD FieldName f «Text to insert after«} | {MERGEFIELD OrderDate f » (Order Date)»} |
Top
Date and Time Formatting Options
Using field codes, you can apply date/time formatting to merge fields
that will bind to database fields of types Date, Time, and Timestamp, or
to an object of type System.DateTime. The general format for applying
date/time format codes is:
{MERGEFIELD FieldName @ "Formatting Pattern"}
Date/Time Format Code | Description | Field Code Example | Output Example |
---|---|---|---|
Day | |||
d | Displays the day of the week or month as a number. Single digit day numbers will not include a leading zero. |
{MERGEFIELD Date @ «M/d/yyyy»} | 4/7/2003 |
dd | Displays the day of the week or month as a number. Single digit day numbers will include a leading zero. |
{MERGEFIELD Date @ «d MMMM yyyy»} | 07 April 2003 |
ddd | Displays a three-letter abbreviation for the day of the week. | {MERGEFIELD Date @ «ddd, d-MMM-yy»} | Mon, 7-Apr-03 |
dddd | Displays the full name of the day of the week. | {MERGEFIELD Date @ «dddd, MMMM d, yyyy»} | Monday, April 7, 2003 |
Month (Use uppercase M for months, lowercase m for minutes) | |||
M | Displays the month as a number. Single digit month numbers will not include a leading zero. |
{MERGEFIELD Date @ «M/d/yy»} | 4/7/03 |
MM | Displays the month as a number. Single digit month numbers will include a leading zero. |
{MERGEFIELD Date @ «yyyy-MM-dd»} | 2003-O4-07 |
MMM | Displays a three-letter month abbreviation. | {MERGEFIELD Date @ «MMM-yy»} | Apr-03 |
MMMM | Displays the full month name | {MERGEFIELD Date @ «MMMM d, yyyy»} | April 7, 2003 |
Year | |||
yy | Displays a two-digit year number. For years 1-9, the year number will include a leading zero. |
{MERGEFIELD Date @ «MMM-yy»} | Apr-03 |
yyyy | Displays a four digit year number | {MERGEFIELD Date @ «MMMM d, yyyy»} | April 7, 2003 |
Hours | |||
h | Use lowercase h to display times based on the 12-hour clock. Lowercase h displays single-digit hours as single-digit numbers, without a leading zero. |
{MERGEFIELD Time @ «h:mm»} | 6:05 |
hh | Use lowercase hh to display times based on the 12-hour clock. Lowercase hh displays single-digit hours with a leading zero. |
{MERGEFIELD Time @ «hh:mm am/pm»} | 06:05 am |
H | Use uppercase H to display times based on the 24-hour clock (military clock). Uppercase H displays single-digit hours as single-digit numbers, without a leading zero. |
{MERGEFIELD Time @ «H:mm»} | 7:05 |
HH | Use uppercase HH to display times based on the 24-hour clock (military clock). Uppercase HH displays single-digit hours with a leading zero. |
{MERGEFIELD Time @ «HH:mm»} | 18:30 |
Minutes (Use lowercase m for minutes, uppercase M for months) | |||
m | Displays single-digit minutes without a leading zero. | {MERGEFIELD Time @ «m ‘minutes'»} | 2 minutes |
mm | Displays single-digit minutes with a leading zero. | {MERGEFIELD Time @ «hh:mm am/pm»} | 06:05 am |
AM & PM | |||
AM/PM | Displays uppercase AM or PM. | {MERGEFIELD Time @ «hh:mm AM/PM»} | 08:30 PM |
am/pm | Displays lowercase am or pm. | {MERGEFIELD Time @ «hh:mm am/pm»} | 07:55 am |
Other Text | |||
‘text‘ | To display text within a date or time, enclose the text in single quotation marks. |
{MERGEFIELD Date @ «hh:mm ‘EST'»} | 06:15 EST |
character | To include a character, such as — (hyphen), in a date or time, do not enclose in quotation marks. |
{MERGEFIELD Date @ «MMM-yy»} | Apr-03 |
Top
Formatting Options Not Supported in WordWriter 1.0
WordWriter 1.0 does not support the Microsoft Word following formatting options:
- Mapped field
- Vertical formatting
- NumberedItem
Top
Copyright © 2003, SoftArtisans, Inc.
on
September 8, 2021, 8:17 AM PDT
3 ways to enter fields in Microsoft Word
Microsoft Word fields house instructions that help you create dynamic content; they’re flexible and powerful, if you know how to use them.
We may be compensated by vendors who appear on this page through methods such as affiliate links or sponsored partnerships. This may influence how and where their products appear on our site, but vendors cannot pay to influence the content of our reviews. For more info, visit our Terms of Use page.
Occasionally, a requirement simply can’t be easily met with the built-in features. Microsoft Word fields are similar to little bits of code that have a specific job. They return values that you can’t easily do in Word any other way. Fortunately, they’re easy to use once you get the hang of entering them properly. In this article, I’ll show you three ways to enter a Word field:
- Use the interface
- Ctrl + F9
- Type and convert
I’m using Microsoft 365 on a Windows 10 64-bit system, but you can use earlier versions. Word fields aren’t supported by Word Online; the original values will display, but they won’t update, nor can you enter them.
SEE: 83 Excel tips every user should master (TechRepublic)
About Word fields
You can insert fields to display content that will change when you update those fields. You might not realize it, but you’re already using fields. Page numbers, merge fields and so on are inserted automatically when you use those features.
You’ll notice as you work your way through the quick examples, that the function key, F9, plays a big part when working with fields. Specifically, here’s what this key does:
- Ctrl + F9 enters a blank field.
- Alt + F9 toggles all the fields in the document.
- Shift + F9 toggles the selected field.
In addition to entering and toggling fields, you can modify them using switches. A switch is an additional bit of information; it always starts with a backslash (). Switches add formats and change the field’s behavior a bit. We won’t include switches in this article, but you’ll want to explore them later.
When you enter a field, the underlying field code will use the following syntax:
{ FIELD NAME Properties Optional switches }
See Table A for an explanation of these elements.
Table A
FIELD TYPE | This is the name of the code and determines what the field does. You’ll often see this part in all uppercase letters, but it isn’t case sensitive. |
Properties | Optional instructions, but not all fields have them. In the interface dialog that you’ll see in the next section, these are referred to as Field Properties. |
Switches | These are specific instructions, often to do with formatting that you can enable or disable. The character always denotes a switch. |
When including fields in a document, remember that anyone viewing the document in Word can view the underlying codes, so be careful about including personal or confidential information. I’ve never run into this situation but it’s worth noting.
Now that you have a good feel for what fields are, let’s start inserting them. We’ll begin with the interface method.
How to insert a Word field using the interface
Word’s interface provides the most comprehensive method for inserting fields. Even if you find another method easier, I encourage you to review the interface so you can learn what fields are available and about their switches.
SEE: Windows 10: Lists of vocal commands for speech recognition and dictation (free PDF) (TechRepublic)
To enter a field using the interface, do the following:
- Position the cursor where you want to insert the field, which can be in the document body, or the header or footer.
- Click the Insert tab and then click the Quick Parts dropdown in the Text group.
- From the dropdown, choose Fields (Figure A).
- The resulting dialog lists the Word fields in the Field Names list, which you can filter using the Categories list. For this simple example, select Author and then select First Capital in the Format list as shown in Figure B.
- Click OK, and you’ll see the author’s name in the document (Figure C).
Figure A
Figure B
Figure C
You may have noticed a few other options in the dialog:
- Field Codes will display the underlying field code.
- Options will display formatting options and other specialized options that are specific to the field.
- Preserve Formatting During Updates does just what it says: it preserves formatting.
You’ll want to explore the list of fields and their many options when you have more time.
You can use the interface to nest fields. After choosing one field, move the cursor inside that field and then return to the list and choose the second field. This capability takes a bit of practice. In fact, many users find it easier to enter a nested field manually.
How to insert a Word field by typing and converting
Perhaps the easiest method to enter any field is to simply type it, select it and then press Ctrl + F9. Doing so converts the text to the field(s). Let’s try this with again, the Author field:
- Position the cursor where you want to insert the field.
- Type Author
- Select the text you just typed (Figure D).
- Press Ctrl + F9 to convert the string into a true field. As you can see, Word adds the brackets.
- To display the field value instead of the field, press F9.
Figure D
This is a quick and easy way to enter a single field when you know the field code and any switches you might want to include. You can also use this method to insert a nested field, but you must insert each individually. You can’t type out an entire string and convert all the fields at once.
How to insert a Word field by using Ctrl + F9
The third method is similar to the previous method. Press Ctrl + F9 to insert a pair of empty brackets and then type the field code and any switches. Let’s try this method with the same { Author } field:
- Position the cursor where you want to insert the field.
- Press Ctrl + F9 to enter a blank field, as shown in Figure E.
- Enter the field code Author inside the brackets and press F9 to calculate the result.
Figure E
Word displays a field’s results rather than the field code, by default. Right-clicking serves as a toggle to display the underlying field code instead of its result. Doing so converts only the one field, so this is an easy way to quickly edit only one field.
For a full list of field codes, visit List of field codes in Word.
Also See
-
How to make fewer mistakes and work more efficiently using predictive text in Microsoft 365
(TechRepublic) -
How to use the many text wrapping options in Microsoft Word
(TechRepublic) -
Microsoft 365: A cheat sheet
(TechRepublic) -
Zoom vs. Microsoft Teams, Google Meet, Cisco WebEx and Skype: Choosing the right video-conferencing apps for you (free PDF)
(TechRepublic) -
Checklist: Securing Windows 10 systems
(TechRepublic Premium) -
Must-read coverage: Windows 10
(TechRepublic on Flipboard)
-
Microsoft
-
Software