Contact Us

If you still have questions or prefer to get help directly from an agent, please submit a request.
We’ll get back to you as soon as possible.

Please fill out the contact form below and we will reply as soon as possible.

  • Merchanter
English (UK)
US English (US)
GB English (UK)
  • Home
  • How to use Merchanter
  • System Settings & Administration
  • Documents, Printing & Email

How to use IF Statements for fields in Word document Templates

Written by Ian Oldrey

Updated at December 16th, 2025

Contact Us

If you still have questions or prefer to get help directly from an agent, please submit a request.
We’ll get back to you as soon as possible.

Please fill out the contact form below and we will reply as soon as possible.

  • Getting Started
    Training Sessions
  • How to use Merchanter
    Sales Invoicing & Credits Products Purchasing Stock Control OData System Settings & Administration Milling & Value Added Processing Sales Order Processing Customers System Release Updates Pricing & Costs Certification Order Picking Agency Sales Suppliers
  • API Documentation
  • Integrations
    Sage 50 Woo Commerce ECS Webshop Link NearSt QuickBooks Xero ShopWired
  • FAQs
  • Industry Articles
+ More

Table of Contents

What an IF statement in Word is Simple example (most common) Common use cases 1. Mail Merge conditions 2. Show / hide clauses 3. Numeric comparison 4. Nested IF statements How to work with IF fields properly Toggle field code view Update fields Common mistakes (very common) When Word IF statements are the wrong tool Quick checklist

To add conditional logic inside Microsoft Word documents, Word supports IF statements using Field Codes, not normal formulas.

What an IF statement in Word is

Word uses this syntax:

{ IF condition "True result" "False result" }

⚠️ Curly braces must be inserted with the keyboard, not typed.

Insert field braces:
👉 Ctrl + F9


Simple example (most common)

Show text only if a value matches

{ IF "{ MERGEFIELD Status }" = "Approved" "Approved ✔" "Pending" }

Used heavily in:

Contracts

Letters

Reports

Mail merge documents


Common use cases

1. Mail Merge conditions

Example: Different greeting based on title

{ IF "{ MERGEFIELD Title }" = "Dr" "Dear Doctor" "Dear { MERGEFIELD FirstName }" }

2. Show / hide clauses

Example: Include a paragraph only if a checkbox is Yes

{ IF "{ REF IncludeClause }" = "Yes"
"This clause applies."
"" }

(Empty quotes = show nothing)


3. Numeric comparison

{ IF { MERGEFIELD Amount } > 10000 "Senior approval required" "" }

Supported operators:

=

>

<

>=

<=

<> (not equal)


4. Nested IF statements

Yes, they work — but keep them readable.

{ IF "{ MERGEFIELD Type }" = "A"
"Type A terms"
{ IF "{ MERGEFIELD Type }" = "B"
"Type B terms"
"Standard terms"
} }

How to work with IF fields properly

Toggle field code view

Alt + F9 → show all field codes

Shift + F9 → toggle selected field

Update fields

Select document → F9

Or right-click field → Update Field


Common mistakes (very common)

❌ Typing {} manually
❌ Forgetting quotes around text
❌ Spaces inside merge field names
❌ Not updating fields after changes


When Word IF statements are the wrong tool

If you need:

  • Complex logic
  • Calculations
  • Repeating data
  • Validation rules

 


Quick checklist

✔ Use Ctrl + F9
✔ Wrap text in quotes
✔ Update fields
✔ Keep logic simple


conditional statements template fields

Was this article helpful?

Yes
No
Give feedback about this article

Related Articles

  • How to manage stock locations
  • How to Set PIN for User Accounts.
Solution Vendor Color.png

sales@ten-25.co.uk

01202 861606

The Little House, The Street, Wonersh, Guildford, GU5 OPF

BMF Service Member logo.jpg
  • linkedin
  • twitter
  • facebook
Privacy Policy

©2020 by Ten-25 Software Ltd.. Proudly created with Wix.com

Expand