Table of Contents

Class AddressFields

Namespace
DocWright.MailMerge
Assembly
DocWright.MailMerge.dll

Word's address fields (Phase 167): what ADDRESSBLOCK and GREETINGLINE are made of, and how a list's columns are matched to them, as Word's Match Fields does before anyone changes it.

public static class AddressFields
Inheritance
AddressFields
Inherited Members

Remarks

A column matches a field by its name, compared without case, spaces or punctuation: the field's own name, or one of the names Word was measured to take for it (tools/Probe-WordAddressBlock.ps1: Title, Given Name, Surname, Company Name, Address Line 1, ZIP Code, Postcode, Country; Word leaves Street, Town and Organisation unmatched, and so does this).

Fields

Address1

The first address line.

Address2

The second address line.

City

The city.

Company

The company.

Country

The country or region.

CourtesyTitle

The courtesy title (Mr., Dr.).

FirstName

The first name.

JobTitle

The job title.

LastName

The last name.

MiddleName

The middle name.

Nickname

The nickname.

PostalCode

The postal code.

State

The state or province.

Suffix

The suffix (Jr.).

Properties

All

Gets every address field, in Word's order.

Methods

Match(IEnumerable<string>)

Matches a list's columns to the address fields, as Word does: each field takes the first column of one of its names.